Merge pull request #165 from mardy/master

Update ubuntu version
This commit is contained in:
Hauke Schade 2016-04-10 10:59:51 +02:00
commit 0545abdfc0
17 changed files with 75 additions and 69 deletions

View file

@ -10,23 +10,25 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
Page { Page {
id: categoriesPage id: categoriesPage
title: qsTr("Tiny Tiny RSS Reader")
property var categories property var categories
head { header: PageHeader {
actions: [ title: qsTr("Tiny Tiny RSS Reader")
flickable: listView
trailingActionBar.actions: [
Action { Action {
iconName: "settings" iconName: "settings"
onTriggered: pageStack.push(Qt.resolvedUrl("Settings.qml")) onTriggered: pageStack.push(Qt.resolvedUrl("Settings.qml"))
} }
] ]
sections { extension: Sections {
anchors { left: parent.left; right: parent.right; bottom: parent.bottom }
model: [ qsTr("Unread"), qsTr("All") ] model: [ qsTr("Unread"), qsTr("All") ]
selectedIndex: settings.showAll ? 1 : 0 selectedIndex: settings.showAll ? 1 : 0
onSelectedIndexChanged: { onSelectedIndexChanged: {

View file

@ -10,8 +10,8 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 0.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 0.1 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
ListItem.SingleValue { ListItem.SingleValue {
id: listItem id: listItem

View file

@ -10,10 +10,10 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 1.0 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
import Ubuntu.Components.Popups 1.0 import Ubuntu.Components.Popups 1.3
import Ubuntu.Content 1.1 import Ubuntu.Content 1.3
ActionSelectionPopover { ActionSelectionPopover {
id: root id: root

View file

@ -10,8 +10,8 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 0.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 0.1 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
ListItem.Empty { ListItem.Empty {
id: listItem id: listItem

View file

@ -10,8 +10,8 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
import Ubuntu.Components.Popups 1.0 import Ubuntu.Components.Popups 1.3
Item { Item {
id: root id: root

View file

@ -10,8 +10,8 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 0.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 0.1 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
ListItem.Empty { ListItem.Empty {
id: listItem id: listItem

View file

@ -10,7 +10,7 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
Page { Page {
id: root id: root
@ -21,23 +21,25 @@ Page {
property alias currentItem: listView.currentItem property alias currentItem: listView.currentItem
anchors.fill: parent anchors.fill: parent
title: currentItem ? currentItem.title : ""
flickable: currentItem ? currentItem.flickable : null
head.actions: [ header: PageHeader {
Action { title: currentItem ? currentItem.title : ""
iconSource: "../resources/ic_star_"+(currentItem.marked?"enabled":"disabled")+".png" flickable: currentItem ? currentItem.flickable : null
onTriggered: { trailingActionBar.actions: [
model.toggleStar() Action {
iconSource: "../resources/ic_star_"+(currentItem.marked?"enabled":"disabled")+".png"
onTriggered: {
model.toggleStar()
}
},
Action {
iconSource: "../resources/ic_"+(currentItem.unread?"unread":"read")+".png"
onTriggered: {
model.toggleRead()
}
} }
}, ]
Action { }
iconSource: "../resources/ic_"+(currentItem.unread?"unread":"read")+".png"
onTriggered: {
model.toggleRead()
}
}
]
ListView { ListView {
id: listView id: listView

View file

@ -10,15 +10,13 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 1.0 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
Page { Page {
id: feeditemsPage id: feeditemsPage
property variant feed property variant feed
title: feed.title
Component.onCompleted: { Component.onCompleted: {
feedItemModel.feed = feeditemsPage.feed feedItemModel.feed = feeditemsPage.feed
feedItemModel.hasMoreItems = false feedItemModel.hasMoreItems = false
@ -30,8 +28,18 @@ Page {
pullToRefresh.enabled = true pullToRefresh.enabled = true
} }
head { header: PageHeader {
sections { title: feed.title
flickable: listView
trailingActionBar.actions: [
Action {
text: qsTr('Mark all read')
iconName: "tick"
onTriggered: feedItemModel.catchUp()
}
]
extension: Sections {
anchors { left: parent.left; right: parent.right; bottom: parent.bottom }
model: [ qsTr("Unread"), qsTr("All") ] model: [ qsTr("Unread"), qsTr("All") ]
selectedIndex: settings.showAll ? 1 : 0 selectedIndex: settings.showAll ? 1 : 0
onSelectedIndexChanged: { onSelectedIndexChanged: {
@ -47,14 +55,6 @@ Page {
} }
} }
} }
actions: [
Action {
text: qsTr('Mark all read')
iconName: "tick"
onTriggered: feedItemModel.catchUp()
}
]
} }
ListView { ListView {

View file

@ -10,14 +10,12 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
Page { Page {
id: feedsPage id: feedsPage
property var category property var category
title: category.title
Component.onCompleted: { Component.onCompleted: {
feedModel.category = feedsPage.category feedModel.category = feedsPage.category
feedModel.clear() feedModel.clear()
@ -28,15 +26,18 @@ Page {
pullToRefresh.enabled = true pullToRefresh.enabled = true
} }
head { header: PageHeader {
actions: [ title: category.title
flickable: listView
trailingActionBar.actions: [
Action { Action {
iconName: "settings" iconName: "settings"
onTriggered: pageStack.push(Qt.resolvedUrl("Settings.qml")) onTriggered: pageStack.push(Qt.resolvedUrl("Settings.qml"))
} }
] ]
sections { extension: Sections {
anchors { left: parent.left; right: parent.right; bottom: parent.bottom }
model: [ qsTr("Unread"), qsTr("All") ] model: [ qsTr("Unread"), qsTr("All") ]
selectedIndex: settings.showAll ? 1 : 0 selectedIndex: settings.showAll ? 1 : 0
onSelectedIndexChanged: { onSelectedIndexChanged: {

View file

@ -10,9 +10,9 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
import Ubuntu.Content 1.1 import Ubuntu.Content 1.3
import Ubuntu.DownloadManager 0.1 import Ubuntu.DownloadManager 1.2
Page { Page {
id: root id: root

View file

@ -1,6 +1,6 @@
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 0.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 1.0 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
import Ubuntu.Keyboard 0.1 import Ubuntu.Keyboard 0.1
Item { Item {

View file

@ -20,12 +20,16 @@
*/ */
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 1.1 import Ubuntu.Components 1.3
import Ubuntu.Components.ListItems 1.0 as ListItem import Ubuntu.Components.ListItems 1.3 as ListItem
Page { Page {
id: settingsPage id: settingsPage
title: qsTr("Settings")
header: PageHeader {
title: qsTr("Settings")
flickable: flickable
}
Flickable { Flickable {
id: flickable id: flickable

View file

@ -10,7 +10,7 @@
//in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/. //in /usr/share/common-licenses. If not, see http://www.gnu.org/licenses/.
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 0.1 import Ubuntu.Components 1.3
Item { Item {
id: root id: root

View file

@ -1,5 +1,5 @@
import QtQuick 2.0 import QtQuick 2.0
import Ubuntu.Components 0.1 import Ubuntu.Components 1.3
import "../models/tinytinyrss.js" as TTRss import "../models/tinytinyrss.js" as TTRss
import "../models" 1.0 import "../models" 1.0
@ -10,13 +10,10 @@ import "../models" 1.0
MainView { MainView {
id: rootWindow id: rootWindow
applicationName: Qt.application.name applicationName: Qt.application.name
/* Disabled until QTBUG-43555 is fixed
automaticOrientation: true automaticOrientation: true
*/
width: units.gu(45) width: units.gu(45)
height: units.gu(75) height: units.gu(75)
useDeprecatedToolbar: false
PageStack { PageStack {
id: pageStack id: pageStack

View file

@ -1,5 +1,5 @@
VERSION = 0.5.2 VERSION = 0.5.2
UBUNTU_REVISION = 1 UBUNTU_REVISION = 2
DEFINES += APP_VERSION=\\\"$$VERSION\\\" DEFINES += APP_VERSION=\\\"$$VERSION\\\"
DEFINES += Q_OS_UBUNTU_TOUCH DEFINES += Q_OS_UBUNTU_TOUCH

View file

@ -1,6 +1,6 @@
{ {
\"description\": \"Tiny Tiny RSS client\", \"description\": \"Tiny Tiny RSS client\",
\"framework\": \"ubuntu-sdk-14.10-qml\", \"framework\": \"ubuntu-sdk-15.04.1-qml\",
\"hooks\": { \"hooks\": {
\"ttrss\": { \"ttrss\": {
\"apparmor\": \"ttrss.json\", \"apparmor\": \"ttrss.json\",

View file

@ -4,5 +4,5 @@
"content_exchange_source", "content_exchange_source",
"networking" "networking"
], ],
"policy_version": 1.2 "policy_version": 1.3
} }