on xenial help sign in
Remerge lp:~unity-team/unity8/rotate-n7
commitcf4a47853051586fcb28714a1d4a3e23448c99ed authorAlbert Astals <albert.astals@canonical.com> dateFri 14 Feb 2014, 16:54 (13 years ago) parentd7a66e09f11428
4 files changed+13−28
qml/Components/ApplicationScreenshot.qml+6−11 qml/Shell.qml−15 qml/ShellOrientator.qml+6−1 src/main.cpp+1−1
qml/Components/ApplicationScreenshot.qml+6−11
@@ -15,7 +15,6 @@
1515 */
1616
1717import QtQuick 2.0
18−import QtQuick.Window 2.0
1918import Ubuntu.Components 0.1
2019import Unity.Application 0.1
2120
@@ -51,15 +50,11 @@ Item {
5150 visible: applicationScreenshot.withBackground
5251 }
5352
54− OrientationHelper {
55− orientationAngle: Screen.angleBetween(Screen.primaryOrientation, nativeOrientation) // compensate for Shell rotation
56− transitionEnabled: false
57− ApplicationImage {
58− id: applicationImage
59− objectName: "screenshot image"
60− anchors.fill: parent
61− visible: applicationScreenshot.application != null && ready
62− source: ApplicationManager.findApplication((application) ? application.appId : "")
63− }
53+ ApplicationImage {
54+ id: applicationImage
55+ objectName: "screenshot image"
56+ anchors.fill: parent
57+ visible: applicationScreenshot.application != null && ready
58+ source: ApplicationManager.findApplication((application) ? application.appId : "")
6459 }
6560}
qml/Shell.qml−15
@@ -759,21 +759,6 @@ FocusScope {
759759 value: "unity8"
760760 }
761761
762− OSKController {
763− anchors.topMargin: panel.panelHeight
764− anchors.fill: parent // as needs to know the geometry of the shell
765− }
766−
767− //FIXME: This should be handled in the input stack, keyboard shouldnt propagate
768− MouseArea {
769− anchors.bottom: parent.bottom
770− anchors.left: parent.left
771− anchors.right: parent.right
772− height: shell.applicationManager ? shell.applicationManager.keyboardHeight : 0
773−
774− enabled: shell.applicationManager && shell.applicationManager.keyboardVisible
775− }
776−
777762 Label {
778763 anchors.centerIn: parent
779764 visible: applicationManager.fake
qml/ShellOrientator.qml+6−1
@@ -17,7 +17,7 @@
1717import QtQuick 2.0
1818import QtQuick.Window 2.0
1919import Ubuntu.Components 0.1
20−import Ubuntu.Gestures 0.1
20+import Unity.Application 0.1
2121
2222Item {
2323 id: orientator
@@ -31,7 +31,12 @@ Item {
3131 orientationAngle: Screen.angleBetween(nativeOrientation, Screen.primaryOrientation)
3232 transitionEnabled: false
3333 Shell {
34+ id: shell
3435 anchors.fill: parent
3536 }
3637 }
38+
39+ OSKController {
40+ anchors.fill: parent // as needs to know the geometry of the shell
41+ }
3742}
src/main.cpp+1−1
@@ -93,7 +93,7 @@ int startShell(int argc, const char** argv, void* server)
9393 }
9494
9595 const QByteArray orientation = qgetenv("NATIVE_ORIENTATION");
96− Qt::ScreenOrientation orientationAngle = Qt::PortraitOrientation;
96+ Qt::ScreenOrientation orientationAngle = Qt::PrimaryOrientation;
9797 if (orientation == "landscape") {
9898 orientationAngle = Qt::LandscapeOrientation;
9999 } else if (!orientation.isEmpty() && orientation != "portrait") {