diff --git a/Goober.pro b/Goober.pro
index d9ea75d..13d284e 100644
--- a/Goober.pro
+++ b/Goober.pro
@@ -1,7 +1,7 @@
APP_NAME = Goober
CONFIG += qt warn_on cascades10
-LIBS += -lbbdata -lbbsystem
+LIBS += -lbbdata -lbbsystem -lbb
QT += network
include(config.pri)
diff --git a/assets/.assets.index b/assets/.assets.index
index 6e8d35c..3495f3d 100644
--- a/assets/.assets.index
+++ b/assets/.assets.index
@@ -1,5 +1,6 @@
1
-41
+43
+AboutPage.qml
AppCover.qml
icons/at.png
icons/bell-slash.png
@@ -17,6 +18,7 @@ icons/ic_contact.png
icons/ic_del_bookmarks.png
icons/ic_edit.png
icons/ic_favorite.png
+icons/ic_info.png
icons/ic_reload.png
icons/ic_reply.png
icons/ic_reply_all.png
diff --git a/assets/AboutPage.qml b/assets/AboutPage.qml
new file mode 100644
index 0000000..89ef274
--- /dev/null
+++ b/assets/AboutPage.qml
@@ -0,0 +1,55 @@
+import bb.cascades 1.4
+
+Page {
+
+ property string appversion
+
+ Container {
+ layout: DockLayout {}
+ verticalAlignment: VerticalAlignment.Fill
+ horizontalAlignment: HorizontalAlignment.Fill
+ Container {
+ horizontalAlignment: HorizontalAlignment.Center
+ verticalAlignment: VerticalAlignment.Center
+ Container {
+ horizontalAlignment: HorizontalAlignment.Center
+ Label {
+ text: "Goober"
+ horizontalAlignment: HorizontalAlignment.Center
+ textStyle.fontSize: FontSize.XXLarge
+ }
+ }
+ Container {
+ horizontalAlignment: HorizontalAlignment.Center
+ Label {
+ text: "v%1".arg(appversion)
+ }
+ }
+ Container {
+ horizontalAlignment: HorizontalAlignment.Center
+ topPadding: ui.sdu(2)
+ Label {
+ text: "A short messaging client for the pnut.io network."
+ multiline: true
+ }
+ }
+ Container {
+ horizontalAlignment: HorizontalAlignment.Center
+ topPadding: ui.sdu(2)
+ Label {
+ text: "Copyright © 2016 Morgan McMillian"
+ textStyle.fontSize: FontSize.XSmall
+ textFormat: TextFormat.Html
+ }
+ }
+ Container {
+ horizontalAlignment: HorizontalAlignment.Center
+ topPadding: ui.sdu(3)
+ Label {
+ text: "https://monkeystew.org"
+ textFormat: TextFormat.Html
+ }
+ }
+ }
+ }
+}
\ No newline at end of file
diff --git a/assets/icons/ic_info.png b/assets/icons/ic_info.png
new file mode 100644
index 0000000..145f944
Binary files /dev/null and b/assets/icons/ic_info.png differ
diff --git a/assets/main.qml b/assets/main.qml
index f4e0413..77d37d3 100644
--- a/assets/main.qml
+++ b/assets/main.qml
@@ -37,6 +37,15 @@ TabbedPane {
onTriggered: {
activePane.logout();
}
+ },
+ ActionItem {
+ title: qsTr("About")
+ imageSource: "asset:///icons/ic_info.png"
+ onTriggered: {
+ var page = aboutPage.createObject()
+ page.appversion = _app.appversion()
+ activePane.push(page)
+ }
}
]
}
@@ -156,6 +165,10 @@ TabbedPane {
ComponentDefinition {
id: settingsPage
source: "SettingsPage.qml"
+ },
+ ComponentDefinition {
+ id: aboutPage
+ source: "AboutPage.qml"
}
]
diff --git a/buildnum b/buildnum
index f937f7e..b6e2760 100644
--- a/buildnum
+++ b/buildnum
@@ -1 +1 @@
-233
\ No newline at end of file
+242
\ No newline at end of file
diff --git a/config.pri b/config.pri
index cf67b3d..5f84b1b 100644
--- a/config.pri
+++ b/config.pri
@@ -66,6 +66,7 @@ simulator {
config_pri_assets {
OTHER_FILES += \
+ $$quote($$BASEDIR/assets/AboutPage.qml) \
$$quote($$BASEDIR/assets/AppCover.qml) \
$$quote($$BASEDIR/assets/LoginSheet.qml) \
$$quote($$BASEDIR/assets/NewPostSheet.qml) \
@@ -91,6 +92,7 @@ config_pri_assets {
$$quote($$BASEDIR/assets/icons/ic_del_bookmarks.png) \
$$quote($$BASEDIR/assets/icons/ic_edit.png) \
$$quote($$BASEDIR/assets/icons/ic_favorite.png) \
+ $$quote($$BASEDIR/assets/icons/ic_info.png) \
$$quote($$BASEDIR/assets/icons/ic_reload.png) \
$$quote($$BASEDIR/assets/icons/ic_reply.png) \
$$quote($$BASEDIR/assets/icons/ic_reply_all.png) \
diff --git a/src/applicationui.cpp b/src/applicationui.cpp
index aed9dc8..61e321d 100644
--- a/src/applicationui.cpp
+++ b/src/applicationui.cpp
@@ -23,6 +23,7 @@
#include
#include
#include
+#include
using namespace bb::cascades;
@@ -64,6 +65,7 @@ ApplicationUI::ApplicationUI() :
// Set created root object as the application scene
Application::instance()->setScene(root);
+
}
QVariant ApplicationUI::setting(const QString& key)
@@ -86,3 +88,9 @@ void ApplicationUI::onSystemLanguageChanged()
QCoreApplication::instance()->installTranslator(m_pTranslator);
}
}
+
+QString ApplicationUI::appversion()
+{
+ bb::ApplicationInfo appinfo;
+ return appinfo.version();
+}
diff --git a/src/applicationui.hpp b/src/applicationui.hpp
index cba42ae..46d0e60 100644
--- a/src/applicationui.hpp
+++ b/src/applicationui.hpp
@@ -44,6 +44,7 @@ public:
Q_INVOKABLE QVariant setting(const QString &key);
Q_INVOKABLE void setSetting(const QString &key, const QString &value);
+ Q_INVOKABLE QString appversion();
private slots:
void onSystemLanguageChanged();
private:
diff --git a/translations/Goober.ts b/translations/Goober.ts
index b37ea43..aca0054 100644
--- a/translations/Goober.ts
+++ b/translations/Goober.ts
@@ -200,26 +200,31 @@
-
-
+
+
+
+
+
+
+
-
-
+
+
-
-
+
+
-
-
+
+