Loading mobile/android/android-components/components/browser/state/src/main/java/mozilla/components/browser/state/state/TranslationsBrowserState.kt +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ import mozilla.components.concept.engine.translate.TranslationSupport * See [TranslationsState.translationError] for session level errors. */ data class TranslationsBrowserState( val isTranslationsEnabled: Boolean = true, val isTranslationsEnabled: Boolean = false, val isEngineSupported: Boolean? = null, val offerTranslation: Boolean? = null, val supportedLanguages: TranslationSupport? = null, Loading mobile/android/android-components/components/concept/ai-controls/src/main/java/mozilla/components/concept/ai/controls/AIFeatureBlock.kt +2 −2 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ interface AIFeatureBlock { } private class InMemoryAIFeatureBlock(initialBlocked: Boolean) : AIFeatureBlock { private val _isBlocked = MutableStateFlow(initialBlocked) private val _isBlocked = MutableStateFlow(true) override val isBlocked: Flow<Boolean> = _isBlocked override suspend fun block() { Loading @@ -40,6 +40,6 @@ private class InMemoryAIFeatureBlock(initialBlocked: Boolean) : AIFeatureBlock { } override suspend fun unblock() { _isBlocked.value = false _isBlocked.value = true } } mobile/android/android-components/components/lib/ai-controls/src/main/java/mozilla/components/lib/ai/controls/AIFeatureBlockStorage.kt +4 −4 Original line number Diff line number Diff line Loading @@ -28,11 +28,11 @@ internal interface AIFeatureBlockStorage { } private class InMemoryAiFeatureBlockStorage(initialBlocked: Boolean) : AIFeatureBlockStorage { private val _isBlocked = MutableStateFlow(initialBlocked) private val _isBlocked = MutableStateFlow(true) override val isBlocked: Flow<Boolean> = _isBlocked override suspend fun setBlocked(isBlocked: Boolean) { _isBlocked.value = isBlocked _isBlocked.value = true } } Loading @@ -46,13 +46,13 @@ internal class DataStoreBackedAIFeatureBlockStorage( override val isBlocked: Flow<Boolean> get() = dataStore.data.map { preferences -> preferences[isBlockedKey] ?: false true } override suspend fun setBlocked(isBlocked: Boolean) { dataStore.updateData { it.toMutablePreferences().also { preferences -> preferences[isBlockedKey] = isBlocked preferences[isBlockedKey] = true } } } Loading mobile/android/fenix/app/nimbus.fml.yaml +11 −11 Original line number Diff line number Diff line Loading @@ -323,13 +323,13 @@ features: defaults: - channel: developer value: enabled: true enabled: false - channel: nightly value: enabled: true enabled: false - channel: beta value: enabled: true enabled: false setup-checklist: description: A feature on the home page that allows the user to track onboarding setup progress. Loading Loading @@ -407,42 +407,42 @@ features: description: > Show the primary toolbar entry point into the translations feature. (Translations icon on URL toolbar.) type: Boolean default: true default: false main-flow-browser-menu-enabled: description: > Show the browser menu entry point into the translations feature. ('Translate Page' on browser menu.) type: Boolean default: true default: false page-settings-enabled: description: > Show the page settings entry point within the translations feature. (Gear icon on the translations main flow page.) 'main-flow-toolbar-enabled' or 'main-flow-browser-menu-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false global-settings-enabled: description: > Show the global settings entry point within the translations feature. ('Translation Settings' on the page settings view.) 'page-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false global-lang-settings-enabled: description: > Show the global language options entry point for automatically translating. ('Automatic Translation' on the global settings view.) 'global-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false global-site-settings-enabled: description: > Show the global never translate this site options entry point for site management. ('Never translate these sites' on the global settings view.) 'global-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false downloads-enabled: description: > Show the global language model download options entry point for translations. ('Download languages' on the global settings view.) 'global-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false navigation-toolbar: description: Feature for navigation toolbar. Loading Loading @@ -1276,7 +1276,7 @@ features: defaults: - channel: developer value: enabled: true enabled: false - channel: nightly value: enabled: false Loading mobile/android/fenix/app/src/main/java/org/mozilla/fenix/components/menu/MenuDialogFragment.kt +1 −1 Original line number Diff line number Diff line Loading @@ -390,7 +390,7 @@ class MenuDialogFragment : BottomSheetDialogFragment() { }.collectAsState(initial = false) val isTranslationsEnabled = TranslationsEnabledSettings.dataStore(requireContext()) .isEnabled.collectAsState(true) .isEnabled.collectAsState(false) MenuDialogBottomSheet( modifier = Modifier Loading Loading
mobile/android/android-components/components/browser/state/src/main/java/mozilla/components/browser/state/state/TranslationsBrowserState.kt +1 −1 Original line number Diff line number Diff line Loading @@ -25,7 +25,7 @@ import mozilla.components.concept.engine.translate.TranslationSupport * See [TranslationsState.translationError] for session level errors. */ data class TranslationsBrowserState( val isTranslationsEnabled: Boolean = true, val isTranslationsEnabled: Boolean = false, val isEngineSupported: Boolean? = null, val offerTranslation: Boolean? = null, val supportedLanguages: TranslationSupport? = null, Loading
mobile/android/android-components/components/concept/ai-controls/src/main/java/mozilla/components/concept/ai/controls/AIFeatureBlock.kt +2 −2 Original line number Diff line number Diff line Loading @@ -32,7 +32,7 @@ interface AIFeatureBlock { } private class InMemoryAIFeatureBlock(initialBlocked: Boolean) : AIFeatureBlock { private val _isBlocked = MutableStateFlow(initialBlocked) private val _isBlocked = MutableStateFlow(true) override val isBlocked: Flow<Boolean> = _isBlocked override suspend fun block() { Loading @@ -40,6 +40,6 @@ private class InMemoryAIFeatureBlock(initialBlocked: Boolean) : AIFeatureBlock { } override suspend fun unblock() { _isBlocked.value = false _isBlocked.value = true } }
mobile/android/android-components/components/lib/ai-controls/src/main/java/mozilla/components/lib/ai/controls/AIFeatureBlockStorage.kt +4 −4 Original line number Diff line number Diff line Loading @@ -28,11 +28,11 @@ internal interface AIFeatureBlockStorage { } private class InMemoryAiFeatureBlockStorage(initialBlocked: Boolean) : AIFeatureBlockStorage { private val _isBlocked = MutableStateFlow(initialBlocked) private val _isBlocked = MutableStateFlow(true) override val isBlocked: Flow<Boolean> = _isBlocked override suspend fun setBlocked(isBlocked: Boolean) { _isBlocked.value = isBlocked _isBlocked.value = true } } Loading @@ -46,13 +46,13 @@ internal class DataStoreBackedAIFeatureBlockStorage( override val isBlocked: Flow<Boolean> get() = dataStore.data.map { preferences -> preferences[isBlockedKey] ?: false true } override suspend fun setBlocked(isBlocked: Boolean) { dataStore.updateData { it.toMutablePreferences().also { preferences -> preferences[isBlockedKey] = isBlocked preferences[isBlockedKey] = true } } } Loading
mobile/android/fenix/app/nimbus.fml.yaml +11 −11 Original line number Diff line number Diff line Loading @@ -323,13 +323,13 @@ features: defaults: - channel: developer value: enabled: true enabled: false - channel: nightly value: enabled: true enabled: false - channel: beta value: enabled: true enabled: false setup-checklist: description: A feature on the home page that allows the user to track onboarding setup progress. Loading Loading @@ -407,42 +407,42 @@ features: description: > Show the primary toolbar entry point into the translations feature. (Translations icon on URL toolbar.) type: Boolean default: true default: false main-flow-browser-menu-enabled: description: > Show the browser menu entry point into the translations feature. ('Translate Page' on browser menu.) type: Boolean default: true default: false page-settings-enabled: description: > Show the page settings entry point within the translations feature. (Gear icon on the translations main flow page.) 'main-flow-toolbar-enabled' or 'main-flow-browser-menu-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false global-settings-enabled: description: > Show the global settings entry point within the translations feature. ('Translation Settings' on the page settings view.) 'page-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false global-lang-settings-enabled: description: > Show the global language options entry point for automatically translating. ('Automatic Translation' on the global settings view.) 'global-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false global-site-settings-enabled: description: > Show the global never translate this site options entry point for site management. ('Never translate these sites' on the global settings view.) 'global-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false downloads-enabled: description: > Show the global language model download options entry point for translations. ('Download languages' on the global settings view.) 'global-settings-enabled' must also be enabled for users to access this feature. type: Boolean default: true default: false navigation-toolbar: description: Feature for navigation toolbar. Loading Loading @@ -1276,7 +1276,7 @@ features: defaults: - channel: developer value: enabled: true enabled: false - channel: nightly value: enabled: false Loading
mobile/android/fenix/app/src/main/java/org/mozilla/fenix/components/menu/MenuDialogFragment.kt +1 −1 Original line number Diff line number Diff line Loading @@ -390,7 +390,7 @@ class MenuDialogFragment : BottomSheetDialogFragment() { }.collectAsState(initial = false) val isTranslationsEnabled = TranslationsEnabledSettings.dataStore(requireContext()) .isEnabled.collectAsState(true) .isEnabled.collectAsState(false) MenuDialogBottomSheet( modifier = Modifier Loading