mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1065004 - Provide an option to always open tabs in Private Browsing, amendment.r=liuche
This commit is contained in:
parent
724180c48c
commit
472a3add3f
@ -22,6 +22,7 @@ import org.mozilla.gecko.mozglue.ContextUtils.SafeIntent;
|
||||
import org.mozilla.gecko.mozglue.JNITarget;
|
||||
import org.mozilla.gecko.mozglue.RobocopTarget;
|
||||
import org.mozilla.gecko.sync.setup.SyncAccounts;
|
||||
import org.mozilla.gecko.preferences.GeckoPreferences;
|
||||
import org.mozilla.gecko.util.GeckoEventListener;
|
||||
import org.mozilla.gecko.util.ThreadUtils;
|
||||
|
||||
@ -853,7 +854,7 @@ public class Tabs implements GeckoEventListener {
|
||||
boolean external = (flags & LOADURL_EXTERNAL) != 0;
|
||||
|
||||
final SharedPreferences sharedPrefs = GeckoSharedPrefs.forApp(mAppContext);
|
||||
final boolean isPrivatePref = sharedPrefs.getBoolean("android.not_a_preference.openExternalURLsPrivately", false);
|
||||
final boolean isPrivatePref = sharedPrefs.getBoolean(GeckoPreferences.PREFS_OPEN_URLS_IN_PRIVATE, false);
|
||||
if (isPrivatePref && external) {
|
||||
isPrivate = true;
|
||||
}
|
||||
|
@ -127,7 +127,7 @@ OnSharedPreferenceChangeListener
|
||||
private static final String PREFS_SYNC = NON_PREF_PREFIX + "sync";
|
||||
private static final String PREFS_TRACKING_PROTECTION = "privacy.trackingprotection.enabled";
|
||||
private static final String PREFS_TRACKING_PROTECTION_LEARN_MORE = NON_PREF_PREFIX + "trackingprotection.learn_more";
|
||||
private static final String PREFS_OPEN_URLS_IN_PRIVATE = NON_PREF_PREFIX + "openExternalURLsPrivately";
|
||||
public static final String PREFS_OPEN_URLS_IN_PRIVATE = NON_PREF_PREFIX + "openExternalURLsPrivately";
|
||||
|
||||
private static final String ACTION_STUMBLER_UPLOAD_PREF = AppConstants.ANDROID_PACKAGE_NAME + ".STUMBLER_PREF";
|
||||
|
||||
@ -703,9 +703,9 @@ OnSharedPreferenceChangeListener
|
||||
preferences.removePreference(pref);
|
||||
i--;
|
||||
continue;
|
||||
} else if (AppConstants.RELEASE_BUILD &&
|
||||
} else if (!AppConstants.NIGHTLY_BUILD &&
|
||||
PREFS_OPEN_URLS_IN_PRIVATE.equals(key)) {
|
||||
// Remove UI for opening external links in private borwsing onrelease builds.
|
||||
// Remove UI for opening external links in private browsing on non-Nightly builds.
|
||||
preferences.removePreference(pref);
|
||||
i--;
|
||||
continue;
|
||||
|
Loading…
Reference in New Issue
Block a user