Search
SailfishOS Open Build Service
>
Projects
>
home:sledge
>
lipstick-colorful-home
> 0001-get-wallpaper-back.patch
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File 0001-get-wallpaper-back.patch of Package lipstick-colorful-home
diff --git a/src/qml/MainScreen.qml b/src/qml/MainScreen.qml index c91ddec..569e149 100644 --- a/src/qml/MainScreen.qml +++ b/src/qml/MainScreen.qml @@ -59,6 +59,86 @@ PageStackWindow { anchors.fill: parent + // The background image + Image { + id: background + source: "file:///wallpaper.jpg" + fillMode: Image.Stretch + anchors.fill: pager + + // Black overlay for making white text readable + Rectangle { + id: overlay + anchors.fill: parent + opacity: 0.55 + color: 'black' + } + } + + Image { + id: bottomBar + source: "file:///bottom.png" + anchors.bottom: parent.bottom + z: 150 + + Image { + source: "file:///logo.png" + anchors.centerIn: parent + } + + // Temp + Text { + id: temp + text: "3°" + font.pixelSize: 24 + color: favorites.primaryColor + anchors { + verticalCenter: parent.verticalCenter + left: parent.left + leftMargin: 20 + } + } + + // Clock + Text { + id: displayTime + text: Qt.formatDateTime(wallClock.time, "h:mm ap") + font.pixelSize: 24 + color: favorites.primaryColor + anchors { + verticalCenter: parent.verticalCenter + right: parent.right + rightMargin: 20 + } + } + } + + property variant names: ["Home", "All Apps", "Open Apps"] + + Image { + id: labelPlace + source: "file:///top-right.png" + anchors { + top: parent.top + right: parent.right + } + + Text { + id: labelText + text: desktop.names[pager.currentIndex] + font.pixelSize: 32 + color: favorites.primaryColor + anchors { + top: parent.top + right: parent.right + topMargin: 30 + rightMargin: 40 + } + } + z: 150 + + } + // Pager for swiping between different pages of the home screen Pager { id: pager @@ -89,6 +169,8 @@ PageStackWindow { // Initial view should be the AppLauncher currentIndex: 1 + + onCurrentIndexChanged: labelText.text = desktop.names[pager.currentIndex] } Lockscreen { diff --git a/src/qml/pages/AppSwitcher.qml b/src/qml/pages/AppSwitcher.qml index fd019d2..ee9c59b 100644 --- a/src/qml/pages/AppSwitcher.qml +++ b/src/qml/pages/AppSwitcher.qml @@ -94,7 +94,7 @@ Item { right: parent.right bottom: parent.bottom margins: -1 - bottomMargin: switcherRoot.closeMode ? 0 : -height + bottomMargin: switcherRoot.closeMode ? 45 : -height } Behavior on anchors.bottomMargin { PropertyAnimation { duration: 100 } }