diff --git a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/SettingsActivity.kt b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/SettingsActivity.kt
index a41e2d750..ad9dc2043 100644
--- a/app/src/main/kotlin/com/simplemobiletools/gallery/activities/SettingsActivity.kt
+++ b/app/src/main/kotlin/com/simplemobiletools/gallery/activities/SettingsActivity.kt
@@ -57,9 +57,9 @@ class SettingsActivity : SimpleActivity() {
setupShowMediaCount()
setupKeepLastModified()
setupShowInfoBubble()
+ setupOneFingerZoom()
setupShowExtendedDetails()
setupManageExtendedDetails()
- setupOneFingerZoom()
updateTextColors(settings_holder)
}
@@ -273,27 +273,14 @@ class SettingsActivity : SimpleActivity() {
}
}
- private fun setupScreenRotation() {
- settings_screen_rotation.text = getScreenRotationText()
- settings_screen_rotation_holder.setOnClickListener {
- val items = arrayListOf(
- RadioItem(ROTATE_BY_SYSTEM_SETTING, res.getString(R.string.screen_rotation_system_setting)),
- RadioItem(ROTATE_BY_DEVICE_ROTATION, res.getString(R.string.screen_rotation_device_rotation)),
- RadioItem(ROTATE_BY_ASPECT_RATIO, res.getString(R.string.screen_rotation_aspect_ratio)))
-
- RadioGroupDialog(this@SettingsActivity, items, config.screenRotation) {
- config.screenRotation = it as Int
- settings_screen_rotation.text = getScreenRotationText()
- }
+ private fun setupOneFingerZoom() {
+ settings_one_finger_zoom.isChecked = config.oneFingerZoom
+ settings_one_finger_zoom_holder.setOnClickListener {
+ settings_one_finger_zoom.toggle()
+ config.oneFingerZoom = settings_one_finger_zoom.isChecked
}
}
- private fun getScreenRotationText() = getString(when (config.screenRotation) {
- ROTATE_BY_SYSTEM_SETTING -> R.string.screen_rotation_system_setting
- ROTATE_BY_DEVICE_ROTATION -> R.string.screen_rotation_device_rotation
- else -> R.string.screen_rotation_aspect_ratio
- })
-
private fun setupShowExtendedDetails() {
settings_show_extended_details.isChecked = config.showExtendedDetails
settings_show_extended_details_holder.setOnClickListener {
@@ -314,11 +301,24 @@ class SettingsActivity : SimpleActivity() {
}
}
- private fun setupOneFingerZoom() {
- settings_one_finger_zoom.isChecked = config.oneFingerZoom
- settings_one_finger_zoom_holder.setOnClickListener {
- settings_one_finger_zoom.toggle()
- config.oneFingerZoom = settings_one_finger_zoom.isChecked
+ private fun setupScreenRotation() {
+ settings_screen_rotation.text = getScreenRotationText()
+ settings_screen_rotation_holder.setOnClickListener {
+ val items = arrayListOf(
+ RadioItem(ROTATE_BY_SYSTEM_SETTING, res.getString(R.string.screen_rotation_system_setting)),
+ RadioItem(ROTATE_BY_DEVICE_ROTATION, res.getString(R.string.screen_rotation_device_rotation)),
+ RadioItem(ROTATE_BY_ASPECT_RATIO, res.getString(R.string.screen_rotation_aspect_ratio)))
+
+ RadioGroupDialog(this@SettingsActivity, items, config.screenRotation) {
+ config.screenRotation = it as Int
+ settings_screen_rotation.text = getScreenRotationText()
+ }
}
}
+
+ private fun getScreenRotationText() = getString(when (config.screenRotation) {
+ ROTATE_BY_SYSTEM_SETTING -> R.string.screen_rotation_system_setting
+ ROTATE_BY_DEVICE_ROTATION -> R.string.screen_rotation_device_rotation
+ else -> R.string.screen_rotation_aspect_ratio
+ })
}
diff --git a/app/src/main/res/layout/activity_settings.xml b/app/src/main/res/layout/activity_settings.xml
index 1d3c83420..9dfdfacac 100644
--- a/app/src/main/res/layout/activity_settings.xml
+++ b/app/src/main/res/layout/activity_settings.xml
@@ -447,25 +447,6 @@
-
-
-
-
-
+
+
+
+
+