refactor: Move tab-tap preference to labs (#958)

Allows user feedback on this before promoting to a main feature.
This commit is contained in:
Nik Clayton 2024-09-30 14:57:17 +02:00 committed by GitHub
parent c72060978b
commit fd29987cd1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 7 deletions

View File

@ -25,7 +25,9 @@ import androidx.preference.PreferenceFragmentCompat
import androidx.preference.SwitchPreferenceCompat
import app.pachli.R
import app.pachli.core.preferences.PrefKeys
import app.pachli.core.preferences.TabTapBehaviour
import app.pachli.databinding.FragmentLabPreferencesWarningBinding
import app.pachli.settings.enumListPreference
import app.pachli.settings.makePreferenceScreen
import app.pachli.settings.switchPreference
@ -56,6 +58,13 @@ class LabPreferencesFragment : PreferenceFragmentCompat() {
}
isIconSpaceReserved = false
}
enumListPreference<TabTapBehaviour> {
setDefaultValue(TabTapBehaviour.JUMP_TO_NEXT_PAGE)
setTitle(app.pachli.core.preferences.R.string.pref_title_tab_tap)
key = PrefKeys.TAB_TAP_BEHAVIOUR
isIconSpaceReserved = false
}
}
}

View File

@ -54,7 +54,6 @@ import app.pachli.core.preferences.AppTheme
import app.pachli.core.preferences.DownloadLocation
import app.pachli.core.preferences.PrefKeys
import app.pachli.core.preferences.SharedPreferencesRepository
import app.pachli.core.preferences.TabTapBehaviour
import app.pachli.core.ui.extensions.await
import app.pachli.core.ui.makeIcon
import app.pachli.databinding.AccountNotificationDetailsListItemBinding
@ -301,12 +300,6 @@ class PreferencesFragment : PreferenceFragmentCompat() {
setTitle(R.string.pref_title_enable_swipe_for_tabs)
isSingleLineTitle = false
}
enumListPreference<TabTapBehaviour> {
setDefaultValue(TabTapBehaviour.JUMP_TO_NEXT_PAGE)
setTitle(app.pachli.core.preferences.R.string.pref_title_tab_tap)
key = PrefKeys.TAB_TAP_BEHAVIOUR
}
}
preferenceCategory(app.pachli.core.preferences.R.string.pref_category_downloads) {