I need to lock the screen to a specific orientation for an android app that I'm making.
is there a way to do that in QML? Google didn't get me any answers.
I am using Qt 5.2.
You can basically use the Screen.orientation
property for reading only. See the following example for details:
http://qt-project.org/doc/qt-5/qtquick-window-screeninfo-qml.html
The proper way as of today is to use the Android manifest file for this as done by the Qt Android developer at Digia for his QtHangMan game which is:
<activity android:screenOrientation="portrait" ...
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With