moving the forcePortrait config in the app itself, from Commons

This commit is contained in:
tibbi
2018-10-05 20:39:48 +02:00
parent 10be4e2b88
commit aa6c464321
5 changed files with 9 additions and 9 deletions

View File

@ -35,10 +35,7 @@ class BrightDisplayActivity : SimpleActivity() {
super.onResume()
window.addFlags(WindowManager.LayoutParams.FLAG_KEEP_SCREEN_ON)
toggleBrightness(true)
if (config.forcePortrait) {
requestedOrientation = ActivityInfo.SCREEN_ORIENTATION_PORTRAIT
}
requestedOrientation = if (config.forcePortraitMode) ActivityInfo.SCREEN_ORIENTATION_PORTRAIT else ActivityInfo.SCREEN_ORIENTATION_SENSOR
}
override fun onPause() {