on xenial help sign in
fix camera orientation
commitd67efa60631b20af1dcabb9d2497ac8c16aaded5 authorMichael Zanetti <michael.zanetti@canonical.com> dateFri 5 Aug 2016, 11:47 (10 years ago) parent5add1c4
2 files changed+4−5
qml/Stage/DecoratedWindow.qml+3−4 tests/qmltests/tst_OrientedShell.qml+1−1
qml/Stage/DecoratedWindow.qml+3−4
@@ -26,8 +26,8 @@ FocusScope {
2626 // (minus the window decoration size in case hasDecoration and showDecoration are true)
2727 // The surface might not be able to resize to the requested values. It will return its actual size
2828 // in implicitWidth/implicitHeight.
29− implicitWidth: !counterRotate ? applicationWindow.implicitWidth : applicationWindow.implicitHeight
30− implicitHeight: decorationHeight + (!counterRotate ? applicationWindow.implicitHeight : applicationWindow.implicitWidth)
29+ implicitWidth: applicationWindow.implicitWidth
30+ implicitHeight: decorationHeight + applicationWindow.implicitHeight
3131
3232 property alias application: applicationWindow.application
3333 property alias surface: applicationWindow.surface
@@ -160,6 +160,7 @@ FocusScope {
160160
161161 transform: [
162162 Rotation {
163+ id: rotationTransform
163164 readonly property int rotationAngle: applicationWindow.application &&
164165 applicationWindow.application.rotatesWindowContents
165166 ? ((360 - applicationWindow.surfaceOrientationAngle) % 360) : 0
@@ -184,6 +185,4 @@ FocusScope {
184185
185186 ]
186187 }
187−
188−// Rectangle { anchors.fill: parent; color: "blue"; opacity: .3 }
189188}
tests/qmltests/tst_OrientedShell.qml+1−1
@@ -28,7 +28,7 @@ import Unity.InputInfo 0.1
2828import Utils 0.1
2929
3030import "../../qml"
31−import "Stages"
31+import "Stage"
3232
3333Rectangle {
3434 id: root