fe303435c8
* Fix installing extensions on MIUI * isShizukuReady -> isShizukuInstalled (cherry picked from commit 293b96785865d9cf8c62b3e12046347b32be9d4d) # Conflicts: # app/src/main/java/eu/kanade/presentation/more/settings/screen/SettingsAdvancedScreen.kt
25 lines
875 B
Kotlin
25 lines
875 B
Kotlin
package eu.kanade.domain.base
|
|
|
|
import android.content.Context
|
|
import eu.kanade.tachiyomi.core.preference.PreferenceStore
|
|
import eu.kanade.tachiyomi.util.system.isPreviewBuildType
|
|
import eu.kanade.tachiyomi.util.system.isReleaseBuildType
|
|
|
|
class BasePreferences(
|
|
val context: Context,
|
|
private val preferenceStore: PreferenceStore,
|
|
) {
|
|
|
|
fun confirmExit() = preferenceStore.getBoolean("pref_confirm_exit", false)
|
|
|
|
fun downloadedOnly() = preferenceStore.getBoolean("pref_downloaded_only", false)
|
|
|
|
fun incognitoMode() = preferenceStore.getBoolean("incognito_mode", false)
|
|
|
|
fun automaticExtUpdates() = preferenceStore.getBoolean("automatic_ext_updates", true)
|
|
|
|
fun extensionInstaller() = ExtensionInstallerPreference(context, preferenceStore)
|
|
|
|
fun acraEnabled() = preferenceStore.getBoolean("acra.enable", isPreviewBuildType || isReleaseBuildType)
|
|
}
|