Comment 3 for bug 1484445

Revision history for this message
Gerry Boland (gerboland) wrote :

IMO As Tagger uses the camera, it doesn't make sense for it to ever rotate the camera viewport. Reason is that say you hold your phone at 45 degrees, the UI will perform the rotation animation, which will confuse the user.

Then the app dev to know the actual device orientation, to undo the shell's rotation.

We think a better solution is for the app to not be rotated by the shell at all, but be notified of the device orientation so it can adjust its UI to suit. The Camera app does this currently.

Place "X-Ubuntu-Rotates-Window-Contents=true" in the desktop file. Then the app surface is never rotated, and Screen.orientation will reflect the actual device orientation (i.e. includes Qt.InvertedPortrait and Qt.InvertedLandscape), which you can use to rotate the UI to suit.

Note if the window is not fullscreen, the panel will move on device rotation, meaning your window will be resized a bit. But never rotated