Setting Up Multi Orientation - Android

I am new to Android programming and I have orientation problem.

I want my actions to be displayed only in portrait and reverse portrait and orientation.

I thought it android:screenOrientation="portrait|reversePortrait"would work, but it does not work. Is there a way to do this in the manifest file?

+5
source share
1 answer

Please check the documentation:   http://developer.android.com/guide/topics/manifest/activity-element.html#screen

API 9+ adds portrait orientation, but can be either normal or reverse portrait based on the device’s sensor. So you can use android:screenOrientation="sensorPortrait"for both.

+6

All Articles