summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarco Martin <notmart@gmail.com>2016-05-13 15:58:21 (GMT)
committerMarco Martin <notmart@gmail.com>2016-05-13 15:58:21 (GMT)
commitf4de5d1befa6ed2634bb8e5ed2e5e02c9feb1506 (patch)
tree9fce10bdf8a0728508650b0963ff436d21e98538
parent3b34e223c8c55b99fdf88e6bca866a3fcba2cfc5 (diff)
move progressbar in MainView
only show on controls shown
-rw-r--r--mobile/app/package/contents/ui/MainView.qml13
-rw-r--r--mobile/app/package/contents/ui/main.qml12
2 files changed, 13 insertions, 12 deletions
diff --git a/mobile/app/package/contents/ui/MainView.qml b/mobile/app/package/contents/ui/MainView.qml
index ec791af..8a82231 100644
--- a/mobile/app/package/contents/ui/MainView.qml
+++ b/mobile/app/package/contents/ui/MainView.qml
@@ -18,6 +18,7 @@
*/
import QtQuick 2.1
+import QtQuick.Controls 1.3
import org.kde.okular 2.0 as Okular
import org.kde.kirigami 1.0 as Kirigami
@@ -50,4 +51,16 @@ Kirigami.Page {
target: pageArea.page
onBookmarkedChanged: actions.main.checked = pageArea.page.bookmarked
}
+ ProgressBar {
+ id: bar
+ z: 99
+ visible: applicationWindow().controlsVisible
+ height: Kirigami.Units.smallSpacing
+ anchors {
+ left: parent.left
+ right: parent.right
+ bottom: parent.bottom
+ }
+ value: documentItem.pageCount != 0 ? ((documentItem.currentPage+1) / documentItem.pageCount) : 0
+ }
}
diff --git a/mobile/app/package/contents/ui/main.qml b/mobile/app/package/contents/ui/main.qml
index 09410c8..e030ab1 100644
--- a/mobile/app/package/contents/ui/main.qml
+++ b/mobile/app/package/contents/ui/main.qml
@@ -42,18 +42,6 @@ Kirigami.AbstractApplicationWindow {
}
contextDrawer: OkularDrawer {}
- ProgressBar {
- id: bar
- z: 99
- anchors {
- left: parent.left
- right: parent.right
- bottom: parent.bottom
- }
- height: units.smallSpacing
- value: documentItem.pageCount != 0 ? (documentItem.currentPage / documentItem.pageCount) : 0
- }
-
Okular.DocumentItem {
id: documentItem
onWindowTitleForDocumentChanged: {