summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAleix Pol <[email protected]>2016-11-29 17:26:44 +0100
committerAleix Pol <[email protected]>2016-12-13 16:30:16 +0100
commit47e215364e4812371d092838b88c781993f113d8 (patch)
tree11631b589c4e4d32bac05027d12993cd4ae8c17d
parent5181364a3e06106e71158708de8b78f74a1550ae (diff)
Port
All seems to work fine, tests pass
-rw-r--r--discover/autotests/toplevels.qml2
-rw-r--r--discover/qml/AddonsView.qml2
-rw-r--r--discover/qml/ApplicationDelegate.qml4
-rw-r--r--discover/qml/ApplicationPage.qml2
-rw-r--r--discover/qml/ApplicationScreenshots.qml2
-rw-r--r--discover/qml/ApplicationsListPage.qml4
-rw-r--r--discover/qml/ApplicationsTop.qml2
-rw-r--r--discover/qml/BrowsingPage.qml2
-rw-r--r--discover/qml/CategoryDisplay.qml2
-rw-r--r--discover/qml/DiscoverDrawer.qml18
-rw-r--r--discover/qml/DiscoverPage.qml2
-rw-r--r--discover/qml/DiscoverWindow.qml4
-rw-r--r--discover/qml/Heading.qml2
-rw-r--r--discover/qml/InstalledPage.qml4
-rw-r--r--discover/qml/LabelBackground.qml2
-rw-r--r--discover/qml/LinkButton.qml2
-rw-r--r--discover/qml/PageHeader.qml2
-rw-r--r--discover/qml/ProgressView.qml2
-rw-r--r--discover/qml/ReviewDelegate.qml2
-rw-r--r--discover/qml/ReviewDialog.qml2
-rw-r--r--discover/qml/ReviewsPage.qml2
-rw-r--r--discover/qml/SourcesPage.qml7
-rw-r--r--discover/qml/UpdatesPage.qml2
23 files changed, 36 insertions, 39 deletions
diff --git a/discover/autotests/toplevels.qml b/discover/autotests/toplevels.qml
index c23edb9..b6b12d8 100644
--- a/discover/autotests/toplevels.qml
+++ b/discover/autotests/toplevels.qml
@@ -46,7 +46,7 @@ DiscoverTest
function test_search() {
app.openMode("Browsing");
- var searchField = findChild(appRoot.globalDrawer, "TextField");
+ var searchField = findChild(appRoot.globalDrawer.topContent[0], "TextField");
verify(searchField);
searchField.text = "cocacola"
verify(waitForSignal(appRoot.stack, "currentItemChanged"))
diff --git a/discover/qml/AddonsView.qml b/discover/qml/AddonsView.qml
index 1a473ad..0215280 100644
--- a/discover/qml/AddonsView.qml
+++ b/discover/qml/AddonsView.qml
@@ -4,7 +4,7 @@ import QtQuick.Layouts 1.1
import org.kde.discover 1.0
import org.kde.kquickcontrolsaddons 2.0
import "navigation.js" as Navigation
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Kirigami.OverlaySheet
{
diff --git a/discover/qml/ApplicationDelegate.qml b/discover/qml/ApplicationDelegate.qml
index a6b405a..f31b4d0 100644
--- a/discover/qml/ApplicationDelegate.qml
+++ b/discover/qml/ApplicationDelegate.qml
@@ -25,7 +25,7 @@ import org.kde.discover.app 1.0
import QtQuick.Window 2.1
import org.kde.kcoreaddons 1.0
import "navigation.js" as Navigation
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Kirigami.AbstractListItem
{
@@ -38,6 +38,7 @@ Kirigami.AbstractListItem
ListView.view.currentIndex = index
Navigation.openApplication(application)
}
+ implicitHeight: Kirigami.Units.gridUnit * (compact ? 7 : 10)
Item {
id: lowLayout
@@ -47,7 +48,6 @@ Kirigami.AbstractListItem
margins: Kirigami.Units.largeSpacing
}
- height: Kirigami.Units.gridUnit * (compact ? 7 : 10)
QIconItem {
id: resourceIcon
icon: application.icon
diff --git a/discover/qml/ApplicationPage.qml b/discover/qml/ApplicationPage.qml
index 427ad8f..d453f65 100644
--- a/discover/qml/ApplicationPage.qml
+++ b/discover/qml/ApplicationPage.qml
@@ -25,7 +25,7 @@ import QtGraphicalEffects 1.0
import org.kde.kquickcontrolsaddons 2.0
import org.kde.discover 1.0
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
import "navigation.js" as Navigation
DiscoverPage {
diff --git a/discover/qml/ApplicationScreenshots.qml b/discover/qml/ApplicationScreenshots.qml
index 403f0b4..fa5df78 100644
--- a/discover/qml/ApplicationScreenshots.qml
+++ b/discover/qml/ApplicationScreenshots.qml
@@ -22,7 +22,7 @@ import QtQuick 2.1
import QtQuick.Layouts 1.1
import QtQuick.Controls 1.1
import org.kde.discover 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Flow {
id: root
diff --git a/discover/qml/ApplicationsListPage.qml b/discover/qml/ApplicationsListPage.qml
index bec2c9d..4ed2571 100644
--- a/discover/qml/ApplicationsListPage.qml
+++ b/discover/qml/ApplicationsListPage.qml
@@ -24,7 +24,7 @@ import QtQuick.Window 2.2
import "navigation.js" as Navigation
import org.kde.discover.app 1.0
import org.kde.discover 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
DiscoverPage {
id: page
@@ -38,7 +38,7 @@ DiscoverPage {
property alias extend: appsModel.extends
property alias search: appsModel.search
property alias count: apps.count
- property alias header: apps.header
+ property alias listHeader: apps.header
property bool compact: false
property bool canNavigate: true
readonly property alias subcategories: appsModel.subcategories
diff --git a/discover/qml/ApplicationsTop.qml b/discover/qml/ApplicationsTop.qml
index 3ede424..92eeef2 100644
--- a/discover/qml/ApplicationsTop.qml
+++ b/discover/qml/ApplicationsTop.qml
@@ -24,7 +24,7 @@ import org.kde.discover 1.0
import org.kde.discover.app 1.0
import org.kde.kquickcontrolsaddons 2.0
import "navigation.js" as Navigation
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
ColumnLayout {
id: topView
diff --git a/discover/qml/BrowsingPage.qml b/discover/qml/BrowsingPage.qml
index de997aa..0d0577c 100644
--- a/discover/qml/BrowsingPage.qml
+++ b/discover/qml/BrowsingPage.qml
@@ -24,7 +24,7 @@ import org.kde.discover 1.0
import org.kde.kquickcontrolsaddons 2.0
import org.kde.discover.app 1.0
import "navigation.js" as Navigation
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
DiscoverPage
{
diff --git a/discover/qml/CategoryDisplay.qml b/discover/qml/CategoryDisplay.qml
index 1cdaa06..d016497 100644
--- a/discover/qml/CategoryDisplay.qml
+++ b/discover/qml/CategoryDisplay.qml
@@ -24,7 +24,7 @@ import org.kde.discover 1.0
import org.kde.discover.app 1.0
import org.kde.kquickcontrolsaddons 2.0
import "navigation.js" as Navigation
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
PageHeader {
id: header
diff --git a/discover/qml/DiscoverDrawer.qml b/discover/qml/DiscoverDrawer.qml
index 616d399..b778664 100644
--- a/discover/qml/DiscoverDrawer.qml
+++ b/discover/qml/DiscoverDrawer.qml
@@ -23,7 +23,7 @@ import QtQuick.Layouts 1.1
import QtQuick.Controls 1.1
import org.kde.discover 1.0
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
import "navigation.js" as Navigation
Kirigami.GlobalDrawer {
@@ -148,6 +148,14 @@ Kirigami.GlobalDrawer {
backgroundColor: enabled ? "orange" : Kirigami.Theme.viewBackgroundColor
}
+
+ states: [
+ State {
+ name: "full"
+ when: !Helpers.isCompact
+ PropertyChanges { target: drawer; drawerOpen: true }
+ }
+ ]
}
function rootCategory(cat) {
@@ -206,12 +214,4 @@ Kirigami.GlobalDrawer {
modal: Helpers.isCompact
handleVisible: Helpers.isCompact
-
- states: [
- State {
- name: "full"
- when: !Helpers.isCompact
- PropertyChanges { target: drawer; opened: true }
- }
- ]
}
diff --git a/discover/qml/DiscoverPage.qml b/discover/qml/DiscoverPage.qml
index a3379a4..453e5dc 100644
--- a/discover/qml/DiscoverPage.qml
+++ b/discover/qml/DiscoverPage.qml
@@ -18,7 +18,7 @@
*/
import QtQuick 2.5
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Kirigami.ScrollablePage
{
diff --git a/discover/qml/DiscoverWindow.qml b/discover/qml/DiscoverWindow.qml
index 5318874..8ebd30d 100644
--- a/discover/qml/DiscoverWindow.qml
+++ b/discover/qml/DiscoverWindow.qml
@@ -3,7 +3,7 @@ import QtQuick.Layouts 1.1
import QtQuick.Controls 1.1
import org.kde.discover 1.0
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
import "navigation.js" as Navigation
Kirigami.ApplicationWindow
@@ -152,7 +152,7 @@ Kirigami.ApplicationWindow
}
}
}
- onVisibleChanged: if(!visible) {
+ onSheetOpenChanged: if(!sheetOpen) {
sheet.destroy(1000)
if (!sheet.acted)
transaction.cancel()
diff --git a/discover/qml/Heading.qml b/discover/qml/Heading.qml
index ac56e65..bdbe71e 100644
--- a/discover/qml/Heading.qml
+++ b/discover/qml/Heading.qml
@@ -1,5 +1,5 @@
import QtQuick.Controls 1.1
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Kirigami.Heading {
level: 3
diff --git a/discover/qml/InstalledPage.qml b/discover/qml/InstalledPage.qml
index 39bbb63..cb9b03d 100644
--- a/discover/qml/InstalledPage.qml
+++ b/discover/qml/InstalledPage.qml
@@ -3,7 +3,7 @@ import QtQuick.Controls 1.1
import QtQuick.Layouts 1.1
import org.kde.discover 1.0
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
ApplicationsListPage {
id: page
@@ -15,7 +15,7 @@ ApplicationsListPage {
compact: true
canNavigate: false
- header: PageHeader {
+ listHeader: PageHeader {
width: parent.width
background: "qrc:/icons/installedcrop.jpg"
diff --git a/discover/qml/LabelBackground.qml b/discover/qml/LabelBackground.qml
index 7737c24..1ded3ae 100644
--- a/discover/qml/LabelBackground.qml
+++ b/discover/qml/LabelBackground.qml
@@ -21,7 +21,7 @@ import QtQuick 2.1
import QtQuick.Controls 1.1
import QtQuick.Layouts 1.1
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Item
{
diff --git a/discover/qml/LinkButton.qml b/discover/qml/LinkButton.qml
index d00f0b4..589289c 100644
--- a/discover/qml/LinkButton.qml
+++ b/discover/qml/LinkButton.qml
@@ -1,6 +1,6 @@
import QtQuick 2.2
import QtGraphicalEffects 1.0
-import org.kde.kirigami 1.0
+import org.kde.kirigami 2.0
Text {
id: control
diff --git a/discover/qml/PageHeader.qml b/discover/qml/PageHeader.qml
index 1b315d9..befd921 100644
--- a/discover/qml/PageHeader.qml
+++ b/discover/qml/PageHeader.qml
@@ -22,7 +22,7 @@ import QtQuick.Layouts 1.2
import QtQuick.Controls 1.2
import QtGraphicalEffects 1.0
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
ColumnLayout {
id: root
diff --git a/discover/qml/ProgressView.qml b/discover/qml/ProgressView.qml
index 12f316a..4120779 100644
--- a/discover/qml/ProgressView.qml
+++ b/discover/qml/ProgressView.qml
@@ -3,7 +3,7 @@ import QtQuick.Controls 1.1
import QtQuick.Layouts 1.1
import org.kde.kquickcontrolsaddons 2.0
import org.kde.discover 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
import "navigation.js" as Navigation
Kirigami.BasicListItem {
diff --git a/discover/qml/ReviewDelegate.qml b/discover/qml/ReviewDelegate.qml
index a6625b3..fe99155 100644
--- a/discover/qml/ReviewDelegate.qml
+++ b/discover/qml/ReviewDelegate.qml
@@ -19,7 +19,7 @@
import QtQuick 2.1
import QtQuick.Layouts 1.1
-import org.kde.kirigami 1.0
+import org.kde.kirigami 2.0
import org.kde.discover 1.0
AbstractListItem
diff --git a/discover/qml/ReviewDialog.qml b/discover/qml/ReviewDialog.qml
index 4c23fa5..22dac4c 100644
--- a/discover/qml/ReviewDialog.qml
+++ b/discover/qml/ReviewDialog.qml
@@ -3,7 +3,7 @@ import QtQuick.Controls 1.2
import QtQuick.Dialogs 1.2
import QtQuick.Layouts 1.1
import QtQuick.Window 2.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Kirigami.OverlaySheet
{
diff --git a/discover/qml/ReviewsPage.qml b/discover/qml/ReviewsPage.qml
index ac3daa5..6eda115 100644
--- a/discover/qml/ReviewsPage.qml
+++ b/discover/qml/ReviewsPage.qml
@@ -22,7 +22,7 @@ import QtQuick 2.1
import QtQuick.Controls 1.1
import org.kde.discover 1.0
import org.kde.discover.app 1.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
Kirigami.OverlaySheet {
id: page
diff --git a/discover/qml/SourcesPage.qml b/discover/qml/SourcesPage.qml
index 5859ab1..637dbc0 100644
--- a/discover/qml/SourcesPage.qml
+++ b/discover/qml/SourcesPage.qml
@@ -4,7 +4,7 @@ import QtQuick.Layouts 1.1
import org.kde.discover 1.0
import org.kde.discover.app 1.0
import org.kde.kquickcontrolsaddons 2.0
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
import "navigation.js" as Navigation
DiscoverPage {
@@ -120,6 +120,7 @@ DiscoverPage {
model: sourceBackend.sources
delegate: Kirigami.SwipeListItem {
+ Layout.fillWidth: true
enabled: display.length>0
onClicked: Navigation.openApplicationListSource(model.display)
@@ -138,10 +139,6 @@ DiscoverPage {
]
RowLayout {
- anchors {
- left: parent.left
- right: parent.right
- }
CheckBox {
id: enabledBox
checked: model.checked != Qt.Unchecked
diff --git a/discover/qml/UpdatesPage.qml b/discover/qml/UpdatesPage.qml
index 63d4383..40e5b08 100644
--- a/discover/qml/UpdatesPage.qml
+++ b/discover/qml/UpdatesPage.qml
@@ -6,7 +6,7 @@ import org.kde.discover.app 1.0
import org.kde.kquickcontrolsaddons 2.0
import org.kde.kcoreaddons 1.0
import "navigation.js" as Navigation
-import org.kde.kirigami 1.0 as Kirigami
+import org.kde.kirigami 2.0 as Kirigami
DiscoverPage
{