on xenial help sign in
Polishing the rotation animation
b30d791Daniel d'Andrada
qml/OrientedShell.qml+5−1
@@ -19,7 +19,11 @@ import QtQuick.Window 2.0
19import Ubuntu.Components 0.1
19import Ubuntu.Components 0.1
20import "Components"
20import "Components"
21
21
22−Item {
22+Rectangle {
23+ // white background when dash is shown to better match Dashes own background, making for
24+ // a nicer rotation animation effect. If gives the illusion that the dash is always taking the entire
25+ // screen during the rotation.
26+ color: shell.dashShown ? "white" : "black"
23 id: orientedShell
27 id: orientedShell
24
28
25 // this is only here to select the width / height of the window if not running fullscreen
29 // this is only here to select the width / height of the window if not running fullscreen
qml/Shell.qml+1−2
@@ -56,14 +56,13 @@ FocusScope {
56 return deviceOrientations;
56 return deviceOrientations;
57 }
57 }
58 }
58 }
59+ property bool dashShown: dash.shown && dash.available && underlay.visible
59
60
60 property real edgeSize: units.gu(2)
61 property real edgeSize: units.gu(2)
61 property url defaultBackground: Qt.resolvedUrl(shell.width >= units.gu(60) ? "graphics/tablet_background.jpg" : "graphics/phone_background.jpg")
62 property url defaultBackground: Qt.resolvedUrl(shell.width >= units.gu(60) ? "graphics/tablet_background.jpg" : "graphics/phone_background.jpg")
62 property url background
63 property url background
63 readonly property real panelHeight: panel.panelHeight
64 readonly property real panelHeight: panel.panelHeight
64
65
65− property bool dashShown: dash.shown
66−
67 property bool sideStageEnabled: shell.width >= units.gu(100)
66 property bool sideStageEnabled: shell.width >= units.gu(100)
68
67
69 function activateApplication(appId) {
68 function activateApplication(appId) {