About page for QML UI
This commit is contained in:
parent
7e7bfbe69e
commit
d3c1133610
3 changed files with 120 additions and 26 deletions
|
@ -28,6 +28,10 @@ Python {
|
||||||
property string progname: 'gpodder'
|
property string progname: 'gpodder'
|
||||||
property bool ready: false
|
property bool ready: false
|
||||||
property bool refreshing: false
|
property bool refreshing: false
|
||||||
|
|
||||||
|
property string coreversion
|
||||||
|
property string uiversion
|
||||||
|
|
||||||
signal downloadProgress(int episode_id, real progress)
|
signal downloadProgress(int episode_id, real progress)
|
||||||
signal playbackProgress(int episode_id, real progress)
|
signal playbackProgress(int episode_id, real progress)
|
||||||
signal podcastListChanged()
|
signal podcastListChanged()
|
||||||
|
@ -39,8 +43,11 @@ Python {
|
||||||
|
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
setHandler('hello', function (coreversion, uiversion) {
|
setHandler('hello', function (coreversion, uiversion) {
|
||||||
console.log('gPodder Core ' + coreversion);
|
py.coreversion = coreversion;
|
||||||
console.log('gPodder QML UI ' + uiversion);
|
py.uiversion = uiversion;
|
||||||
|
|
||||||
|
console.log('gPodder Core ' + py.coreversion);
|
||||||
|
console.log('gPodder QML UI ' + py.uiversion);
|
||||||
console.log('PyOtherSide ' + py.pluginVersion());
|
console.log('PyOtherSide ' + py.pluginVersion());
|
||||||
console.log('Python ' + py.pythonVersion());
|
console.log('Python ' + py.pythonVersion());
|
||||||
});
|
});
|
||||||
|
|
83
touch/AboutPage.qml
Normal file
83
touch/AboutPage.qml
Normal file
|
@ -0,0 +1,83 @@
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* gPodder QML UI Reference Implementation
|
||||||
|
* Copyright (c) 2013, Thomas Perl <m@thp.io>
|
||||||
|
*
|
||||||
|
* Permission to use, copy, modify, and/or distribute this software for any
|
||||||
|
* purpose with or without fee is hereby granted, provided that the above
|
||||||
|
* copyright notice and this permission notice appear in all copies.
|
||||||
|
*
|
||||||
|
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||||
|
* REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||||
|
* AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||||
|
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||||
|
* LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
||||||
|
* OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||||
|
* PERFORMANCE OF THIS SOFTWARE.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
import QtQuick 2.0
|
||||||
|
|
||||||
|
SlidePage {
|
||||||
|
id: aboutPage
|
||||||
|
|
||||||
|
Flickable {
|
||||||
|
id: flickable
|
||||||
|
anchors.fill: parent
|
||||||
|
boundsBehavior: Flickable.StopAtBounds
|
||||||
|
|
||||||
|
contentWidth: detailColumn.width
|
||||||
|
contentHeight: detailColumn.height + detailColumn.spacing
|
||||||
|
|
||||||
|
Column {
|
||||||
|
id: detailColumn
|
||||||
|
|
||||||
|
width: aboutPage.width
|
||||||
|
spacing: 5 * pgst.scalef
|
||||||
|
|
||||||
|
SlidePageHeader {
|
||||||
|
title: 'About gPodder'
|
||||||
|
}
|
||||||
|
|
||||||
|
SectionHeader {
|
||||||
|
text: 'How to use'
|
||||||
|
width: parent.width
|
||||||
|
}
|
||||||
|
|
||||||
|
PLabel {
|
||||||
|
width: parent.width * .9
|
||||||
|
font.pixelSize: 30 * pgst.scalef
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
wrapMode: Text.WordWrap
|
||||||
|
text: 'Swipe left on a page to reveal the menu for that page. Go back by swiping pages to the right.\n\nAdd subscriptions via their feed URL or use gpodder.net to search for podcasts.'
|
||||||
|
}
|
||||||
|
|
||||||
|
SectionHeader {
|
||||||
|
text: 'More information'
|
||||||
|
width: parent.width
|
||||||
|
}
|
||||||
|
|
||||||
|
PLabel {
|
||||||
|
width: parent.width * .9
|
||||||
|
font.pixelSize: 20 * pgst.scalef
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
wrapMode: Text.WordWrap
|
||||||
|
text: [
|
||||||
|
'© 2005-2014 Thomas Perl and the gPodder Team',
|
||||||
|
'License: ISC / GPLv3 or later',
|
||||||
|
'Website: http://gpodder.org/',
|
||||||
|
'',
|
||||||
|
'gPodder Core ' + py.coreversion,
|
||||||
|
'gPodder QML UI ' + py.uiversion,
|
||||||
|
'PyOtherSide ' + py.pluginVersion(),
|
||||||
|
'Python ' + py.pythonVersion()
|
||||||
|
].join('\n')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
PScrollDecorator { flickable: flickable }
|
||||||
|
}
|
||||||
|
|
|
@ -27,6 +27,19 @@ import 'common/util.js' as Util
|
||||||
SlidePage {
|
SlidePage {
|
||||||
id: startPage
|
id: startPage
|
||||||
canClose: false
|
canClose: false
|
||||||
|
hasPull: true
|
||||||
|
|
||||||
|
PullMenu {
|
||||||
|
PullMenuItem {
|
||||||
|
text: 'Now Playing'
|
||||||
|
color: Constants.colors.playback
|
||||||
|
icon: Icons.play
|
||||||
|
onClicked: {
|
||||||
|
pgst.loadPage('PlayerPage.qml');
|
||||||
|
startPage.unPull();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
function update_stats() {
|
function update_stats() {
|
||||||
py.call('main.get_stats', [], function (result) {
|
py.call('main.get_stats', [], function (result) {
|
||||||
|
@ -182,35 +195,26 @@ SlidePage {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
ButtonArea {
|
Repeater {
|
||||||
onClicked: pgst.loadPage('PlayerPage.qml');
|
model: ListModel {
|
||||||
|
ListElement { caption: 'gpodder.net'; target: 'Directory.qml' }
|
||||||
anchors {
|
ListElement { caption: 'Help'; target: 'AboutPage.qml' }
|
||||||
left: freshEpisodes.left
|
|
||||||
right: freshEpisodes.right
|
|
||||||
}
|
}
|
||||||
|
|
||||||
height: 100 * pgst.scalef
|
delegate: ButtonArea {
|
||||||
|
onClicked: pgst.loadPage(target)
|
||||||
|
|
||||||
PLabel {
|
anchors {
|
||||||
anchors.centerIn: parent
|
left: freshEpisodes.left
|
||||||
text: 'Now playing'
|
right: freshEpisodes.right
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
ButtonArea {
|
height: 80 * pgst.scalef
|
||||||
onClicked: pgst.loadPage('Directory.qml');
|
|
||||||
|
|
||||||
anchors {
|
PLabel {
|
||||||
left: freshEpisodes.left
|
anchors.centerIn: parent
|
||||||
right: freshEpisodes.right
|
text: caption
|
||||||
}
|
}
|
||||||
|
|
||||||
height: 100 * pgst.scalef
|
|
||||||
|
|
||||||
PLabel {
|
|
||||||
anchors.centerIn: parent
|
|
||||||
text: 'gpodder.net'
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue