fixed SENSOR_LANDSCAPE and SENSOR_PORTRAIT mode false nativeResume bug

This commit is contained in:
dmuratshin 2017-01-12 10:58:35 -08:00
parent acd76826cd
commit 01f66613db
1 changed files with 2 additions and 2 deletions

View File

@ -1169,12 +1169,12 @@ class SDLSurface extends SurfaceView implements SurfaceHolder.Callback,
{
// Accept any
}
else if (requestedOrientation == ActivityInfo.SCREEN_ORIENTATION_PORTRAIT)
else if (requestedOrientation == ActivityInfo.SCREEN_ORIENTATION_PORTRAIT || requestedOrientation == ActivityInfo.SCREEN_ORIENTATION_SENSOR_PORTRAIT)
{
if (mWidth > mHeight) {
skip = true;
}
} else if (requestedOrientation == ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE) {
} else if (requestedOrientation == ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE || requestedOrientation == ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE) {
if (mWidth < mHeight) {
skip = true;
}