ma1 pushed to branch tor-browser-147.0a1-16.0-2 at The Tor Project / Applications / Tor Browser
Commits:
-
3aaba973
by hackademix at 2026-01-26T20:40:28+01:00
3 changed files:
- mobile/android/fenix/app/src/main/java/org/mozilla/fenix/components/TorBrowserFeatures.kt
- mobile/android/fenix/app/src/main/java/org/mozilla/fenix/utils/Settings.kt
- mobile/android/fenix/app/src/main/res/values/preference_keys.xml
Changes:
| ... | ... | @@ -115,15 +115,19 @@ object TorBrowserFeatures { |
| 115 | 115 | )
|
| 116 | 116 | }
|
| 117 | 117 | /**
|
| 118 | - * Install NoScript as a user WebExtension if we have not already done so.
|
|
| 118 | + * Install NoScript if we have not done it yet for this browser version.
|
|
| 119 | 119 | * AMO signature is checked, but automatic updates still need to be enabled.
|
| 120 | 120 | */
|
| 121 | - if (!settings.noscriptInstalled) {
|
|
| 121 | + val extensionsVersion =
|
|
| 122 | + org.mozilla.geckoview.BuildConfig.MOZ_APP_VERSION + "-" +
|
|
| 123 | + org.mozilla.geckoview.BuildConfig.MOZ_APP_BUILDID + "-" +
|
|
| 124 | + org.mozilla.fenix.BuildConfig.VCS_HASH
|
|
| 125 | + if (settings.extensionsVersion != extensionsVersion) {
|
|
| 122 | 126 | installNoScript(
|
| 123 | 127 | context,
|
| 124 | 128 | runtime,
|
| 125 | 129 | onSuccess = {
|
| 126 | - settings.noscriptInstalled = true
|
|
| 130 | + settings.extensionsVersion = extensionsVersion
|
|
| 127 | 131 | logger.debug("NoScript extension was installed successfully")
|
| 128 | 132 | },
|
| 129 | 133 | onError = { throwable ->
|
| ... | ... | @@ -2481,14 +2481,9 @@ class Settings( |
| 2481 | 2481 | default = false,
|
| 2482 | 2482 | )
|
| 2483 | 2483 | |
| 2484 | - var noscriptInstalled by booleanPreference(
|
|
| 2485 | - appContext.getPreferenceKey(R.string.pref_key_noscript_installed),
|
|
| 2486 | - default = false
|
|
| 2487 | - )
|
|
| 2488 | - |
|
| 2489 | - var noscriptUpdated by intPreference(
|
|
| 2490 | - appContext.getPreferenceKey(R.string.pref_key_noscript_updated),
|
|
| 2491 | - default = 0
|
|
| 2484 | + var extensionsVersion by stringPreference(
|
|
| 2485 | + appContext.getPreferenceKey(R.string.pref_key_extensions_version),
|
|
| 2486 | + default = ""
|
|
| 2492 | 2487 | )
|
| 2493 | 2488 | |
| 2494 | 2489 | var httpsEverywhereRemoved by booleanPreference(
|
| ... | ... | @@ -523,8 +523,7 @@ |
| 523 | 523 | <string name="pref_key_tab_manager_enhancements" translatable="false">pref_key_tab_manager_enhancements</string>
|
| 524 | 524 | <string name="pref_key_tab_manager_opening_animation" translatable="false">pref_key_tab_manager_opening_animation</string>
|
| 525 | 525 | |
| 526 | - <string name="pref_key_noscript_installed" translatable="false">pref_key_noscript_installed</string>
|
|
| 527 | - <string name="pref_key_noscript_updated" translatable="false">pref_key_noscript_updated</string>
|
|
| 526 | + <string name="pref_key_extensions_version" translatable="false">pref_key_extensions_version</string>
|
|
| 528 | 527 | <string name="pref_key_https_everywhere_removed" translatable="false">pref_key_https_everywhere_removed</string>
|
| 529 | 528 | |
| 530 | 529 | <!-- Security Level Settings -->
|