Search code examples
androidscreen-orientationscreen-rotation

Sensor landscape allows orientation issue in Android


When set to landscape the screen is fixed but when set to sensor landscape it can rotate to any orientation. I don't understand why it wont lock to landscape and reverse landscape as desired.

It is set in the manifest file.

I get no errors or warnings.

Thanks in advance for any help.


Solution

  • Resolved! The compiler had cached a previous version of the manifest file instead of building it every time like the APK. To fix it I deleted the generated files and folders like bin and gen etc.