on xenial help sign in
Remove orientation-support code from Shell.qml. Shimmy things around to reduce delta
commit4aa5c3bfe72581fd996de69b3fbcdbbce71805b6 authorGerry Boland <gerry.boland@canonical.com> dateTue 8 Jul 2014, 20:02 (12 years ago) parent614761a
1 file changed+5−25
qml/Shell.qml+5−25
qml/Shell.qml+5−25
@@ -37,37 +37,17 @@ import Unity.Session 0.1
3737FocusScope {
3838 id: shell
3939
40− property int supportedScreenOrientations: {
41− // check device name and fix orientation if necessary
42− var deviceOrientations;
43− if (applicationArguments.device() === "flo") {
44− deviceOrientations = Qt.InvertedLandscapeOrientation;
45− } else if (applicationArguments.device() === "manta") {
46− deviceOrientations = Qt.LandscapeOrientation;
47− } else if (applicationArguments.device() === "mako") {
48− deviceOrientations = Qt.PortraitOrientation
49− | Qt.InvertedPortraitOrientation
50− | Qt.LandscapeOrientation
51− | Qt.InvertedLandscapeOrientation;
52− }
53−
54− if (stages.shown && ApplicationManager.topmostApplication) {
55− return deviceOrientations & ApplicationManager.topmostApplication.supportedOrientations;
56− } else {
57− return deviceOrientations;
58− }
59− }
60− property bool dashShown: dash.shown && dash.available && underlay.visible
40+ // this is only here to select the width / height of the window if not running fullscreen
41+ property bool tablet: false
42+ width: tablet ? units.gu(160) : applicationArguments.hasGeometry() ? applicationArguments.width() : units.gu(40)
43+ height: tablet ? units.gu(100) : applicationArguments.hasGeometry() ? applicationArguments.height() : units.gu(71)
6144
6245 property real edgeSize: units.gu(2)
6346 property url defaultBackground: Qt.resolvedUrl(shell.width >= units.gu(60) ? "graphics/tablet_background.jpg" : "graphics/phone_background.jpg")
6447 property url background
6548 readonly property real panelHeight: panel.panelHeight
6649
67− // this is only here to select the width / height of the window if not running fullscreen
68− property bool tablet: false
69− width: tablet ? units.gu(160) : applicationArguments.hasGeometry() ? applicationArguments.width() : units.gu(40)
70− height: tablet ? units.gu(100) : applicationArguments.hasGeometry() ? applicationArguments.height() : units.gu(71)
50+ property bool dashShown: dash.shown && dash.available && underlay.visible
7151
7252 property bool sideStageEnabled: shell.width >= units.gu(100)
7353