Change natural orientation to landscape

254 views
Skip to first unread message

Samjith Sadasivan

unread,
Jun 29, 2016, 7:26:25 AM6/29/16
to android-platform
I am trying to change change the natural orientation of tablet device to landscape
which currently is portrait.

With setting persist.panel.orientation to 90 , default orientation changes to landscape.

But getWindowManager().getDefaultDisplay().getRotation() returns 1 indicating 90 degrees rotation.

Google API documentation says , rotation should be 0 ( no rotation) in natural orientation.

https://developer.android.com/reference/android/view/Display.html#getRotation()
Returns the rotation of the screen from its "natural" orientation. The returned value may be Surface.ROTATION_0 (no rotation), Surface.ROTATION_90, Surface.ROTATION_180, or Surface.ROTATION_270. 

Could some one help to confirm the right approach ?

 

Ohad Moisi

unread,
Oct 8, 2016, 7:00:59 PM10/8/16
to android-platform
Hi,
Have you solved this issue? I'm having the same on Android Kitkat.
I assume the WindowManager or
WindowService does not take into account the persist.panel.orientation parameter, I'm checking on it.

Ekrembo

 
Reply all
Reply to author
Forward
0 new messages