added about page
This commit is contained in:
parent
7162f8fa94
commit
9a5a44bb80
10 changed files with 97 additions and 11 deletions
|
@ -1,7 +1,7 @@
|
||||||
APP_NAME = Goober
|
APP_NAME = Goober
|
||||||
|
|
||||||
CONFIG += qt warn_on cascades10
|
CONFIG += qt warn_on cascades10
|
||||||
LIBS += -lbbdata -lbbsystem
|
LIBS += -lbbdata -lbbsystem -lbb
|
||||||
QT += network
|
QT += network
|
||||||
|
|
||||||
include(config.pri)
|
include(config.pri)
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
1
|
1
|
||||||
41
|
43
|
||||||
|
AboutPage.qml
|
||||||
AppCover.qml
|
AppCover.qml
|
||||||
icons/at.png
|
icons/at.png
|
||||||
icons/bell-slash.png
|
icons/bell-slash.png
|
||||||
|
@ -17,6 +18,7 @@ icons/ic_contact.png
|
||||||
icons/ic_del_bookmarks.png
|
icons/ic_del_bookmarks.png
|
||||||
icons/ic_edit.png
|
icons/ic_edit.png
|
||||||
icons/ic_favorite.png
|
icons/ic_favorite.png
|
||||||
|
icons/ic_info.png
|
||||||
icons/ic_reload.png
|
icons/ic_reload.png
|
||||||
icons/ic_reply.png
|
icons/ic_reply.png
|
||||||
icons/ic_reply_all.png
|
icons/ic_reply_all.png
|
||||||
|
|
55
assets/AboutPage.qml
Normal file
55
assets/AboutPage.qml
Normal file
|
@ -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: "<a href=\"https://monkeystew.org\">https://monkeystew.org</a>"
|
||||||
|
textFormat: TextFormat.Html
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
BIN
assets/icons/ic_info.png
Normal file
BIN
assets/icons/ic_info.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.8 KiB |
|
@ -37,6 +37,15 @@ TabbedPane {
|
||||||
onTriggered: {
|
onTriggered: {
|
||||||
activePane.logout();
|
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 {
|
ComponentDefinition {
|
||||||
id: settingsPage
|
id: settingsPage
|
||||||
source: "SettingsPage.qml"
|
source: "SettingsPage.qml"
|
||||||
|
},
|
||||||
|
ComponentDefinition {
|
||||||
|
id: aboutPage
|
||||||
|
source: "AboutPage.qml"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
|
|
2
buildnum
2
buildnum
|
@ -1 +1 @@
|
||||||
233
|
242
|
|
@ -66,6 +66,7 @@ simulator {
|
||||||
|
|
||||||
config_pri_assets {
|
config_pri_assets {
|
||||||
OTHER_FILES += \
|
OTHER_FILES += \
|
||||||
|
$$quote($$BASEDIR/assets/AboutPage.qml) \
|
||||||
$$quote($$BASEDIR/assets/AppCover.qml) \
|
$$quote($$BASEDIR/assets/AppCover.qml) \
|
||||||
$$quote($$BASEDIR/assets/LoginSheet.qml) \
|
$$quote($$BASEDIR/assets/LoginSheet.qml) \
|
||||||
$$quote($$BASEDIR/assets/NewPostSheet.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_del_bookmarks.png) \
|
||||||
$$quote($$BASEDIR/assets/icons/ic_edit.png) \
|
$$quote($$BASEDIR/assets/icons/ic_edit.png) \
|
||||||
$$quote($$BASEDIR/assets/icons/ic_favorite.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_reload.png) \
|
||||||
$$quote($$BASEDIR/assets/icons/ic_reply.png) \
|
$$quote($$BASEDIR/assets/icons/ic_reply.png) \
|
||||||
$$quote($$BASEDIR/assets/icons/ic_reply_all.png) \
|
$$quote($$BASEDIR/assets/icons/ic_reply_all.png) \
|
||||||
|
|
|
@ -23,6 +23,7 @@
|
||||||
#include <bb/cascades/QmlDocument>
|
#include <bb/cascades/QmlDocument>
|
||||||
#include <bb/cascades/AbstractPane>
|
#include <bb/cascades/AbstractPane>
|
||||||
#include <bb/cascades/LocaleHandler>
|
#include <bb/cascades/LocaleHandler>
|
||||||
|
#include <bb/ApplicationInfo>
|
||||||
|
|
||||||
using namespace bb::cascades;
|
using namespace bb::cascades;
|
||||||
|
|
||||||
|
@ -64,6 +65,7 @@ ApplicationUI::ApplicationUI() :
|
||||||
|
|
||||||
// Set created root object as the application scene
|
// Set created root object as the application scene
|
||||||
Application::instance()->setScene(root);
|
Application::instance()->setScene(root);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
QVariant ApplicationUI::setting(const QString& key)
|
QVariant ApplicationUI::setting(const QString& key)
|
||||||
|
@ -86,3 +88,9 @@ void ApplicationUI::onSystemLanguageChanged()
|
||||||
QCoreApplication::instance()->installTranslator(m_pTranslator);
|
QCoreApplication::instance()->installTranslator(m_pTranslator);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
QString ApplicationUI::appversion()
|
||||||
|
{
|
||||||
|
bb::ApplicationInfo appinfo;
|
||||||
|
return appinfo.version();
|
||||||
|
}
|
||||||
|
|
|
@ -44,6 +44,7 @@ public:
|
||||||
|
|
||||||
Q_INVOKABLE QVariant setting(const QString &key);
|
Q_INVOKABLE QVariant setting(const QString &key);
|
||||||
Q_INVOKABLE void setSetting(const QString &key, const QString &value);
|
Q_INVOKABLE void setSetting(const QString &key, const QString &value);
|
||||||
|
Q_INVOKABLE QString appversion();
|
||||||
private slots:
|
private slots:
|
||||||
void onSystemLanguageChanged();
|
void onSystemLanguageChanged();
|
||||||
private:
|
private:
|
||||||
|
|
|
@ -200,26 +200,31 @@
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../assets/main.qml" line="59"/>
|
<location filename="../assets/main.qml" line="42"/>
|
||||||
<location filename="../assets/main.qml" line="63"/>
|
<source>About</source>
|
||||||
|
<translation type="unfinished"></translation>
|
||||||
|
</message>
|
||||||
|
<message>
|
||||||
|
<location filename="../assets/main.qml" line="68"/>
|
||||||
|
<location filename="../assets/main.qml" line="72"/>
|
||||||
<source>Home</source>
|
<source>Home</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../assets/main.qml" line="81"/>
|
<location filename="../assets/main.qml" line="90"/>
|
||||||
<location filename="../assets/main.qml" line="85"/>
|
<location filename="../assets/main.qml" line="94"/>
|
||||||
<source>Mentions</source>
|
<source>Mentions</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../assets/main.qml" line="103"/>
|
<location filename="../assets/main.qml" line="112"/>
|
||||||
<location filename="../assets/main.qml" line="107"/>
|
<location filename="../assets/main.qml" line="116"/>
|
||||||
<source>Bookmarks</source>
|
<source>Bookmarks</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
<message>
|
<message>
|
||||||
<location filename="../assets/main.qml" line="125"/>
|
<location filename="../assets/main.qml" line="134"/>
|
||||||
<location filename="../assets/main.qml" line="129"/>
|
<location filename="../assets/main.qml" line="138"/>
|
||||||
<source>Global</source>
|
<source>Global</source>
|
||||||
<translation type="unfinished"></translation>
|
<translation type="unfinished"></translation>
|
||||||
</message>
|
</message>
|
||||||
|
|
Reference in a new issue