diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt index c49551989..f8c464bf4 100644 --- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt +++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/ViewPagerActivity.kt @@ -100,9 +100,9 @@ class ViewPagerActivity : SimpleActivity(), ViewPager.OnPageChangeListener, View supportActionBar?.setBackgroundDrawable(resources.getDrawable(R.drawable.actionbar_gradient_background)) if (config.maxBrightness) { - var attributes = getWindow().getAttributes() - attributes.screenBrightness = 1F - getWindow().setAttributes(attributes) + val attributes = window.attributes + attributes.screenBrightness = 1f + window.attributes = attributes } } diff --git a/app/src/main/res/layout/activity_settings.xml b/app/src/main/res/layout/activity_settings.xml index a67b7f558..856719ac7 100644 --- a/app/src/main/res/layout/activity_settings.xml +++ b/app/src/main/res/layout/activity_settings.xml @@ -149,7 +149,6 @@ -