[tbb-commits] [torbutton/master] Bug 15795: Some security slider prefs do not trigger custom checkbox.

gk at torproject.org gk at torproject.org
Fri Apr 24 18:02:36 UTC 2015


commit cacd8c67be59359b2a9bdf8a2cf2a341401cc77e
Author: Kathy Brade <brade at pearlcrescent.com>
Date:   Fri Apr 24 11:34:54 2015 -0400

    Bug 15795: Some security slider prefs do not trigger custom checkbox.
    
    Also monitor the following prefs. so that all manual changes cause
    the security slider's "custom" checkbox to be toggled:
      mathml.disabled
      network.jar.block-remote-files
      svg.in-content.enabled
---
 src/chrome/content/torbutton.js |    7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/src/chrome/content/torbutton.js b/src/chrome/content/torbutton.js
index 7d229dd..21e567e 100644
--- a/src/chrome/content/torbutton.js
+++ b/src/chrome/content/torbutton.js
@@ -122,11 +122,14 @@ var torbutton_unique_pref_observer =
         this._branch.addObserver("extensions.torbutton", this, false);
         this._branch.addObserver("network.proxy", this, false);
         this._branch.addObserver("network.cookie", this, false);
+        this._branch.addObserver("network.jar", this, false);
         this._branch.addObserver("browser.privatebrowsing.autostart", this, false);
         this._branch.addObserver("javascript", this, false);
         this._branch.addObserver("gfx", this, false);
         this._branch.addObserver("noscript", this, false);
         this._branch.addObserver("media", this, false);
+        this._branch.addObserver("mathml", this, false);
+        this._branch.addObserver("svg", this, false);
 
         // We observe xpcom-category-entry-added for plugins w/ Gecko-Content-Viewers
         var observerService = Cc["@mozilla.org/observer-service;1"].
@@ -140,11 +143,14 @@ var torbutton_unique_pref_observer =
         this._branch.removeObserver("extensions.torbutton", this);
         this._branch.removeObserver("network.proxy", this);
         this._branch.removeObserver("network.cookie", this);
+        this._branch.removeObserver("network.jar", this);
         this._branch.removeObserver("browser.privatebrowsing.autostart", this);
         this._branch.removeObserver("javascript", this);
         this._branch.removeObserver("gfx", this);
         this._branch.removeObserver("noscript", this);
         this._branch.removeObserver("media", this);
+        this._branch.removeObserver("mathml", this);
+        this._branch.removeObserver("svg", this);
 
         var observerService = Cc["@mozilla.org/observer-service;1"].
             getService(Ci.nsIObserverService);
@@ -244,6 +250,7 @@ var torbutton_unique_pref_observer =
             case "gfx.font_rendering.graphite.enabled":
             case "noscript.globalHttpsWhitelist":
             case "noscript.global":
+            case "svg.in-content.enabled":
                 // |m_tb_slider_update| is only set if the user updated a
                 // preference under control of the security slider via the
                 // slider on the Torbutton dialog. This in turn means we can





More information about the tbb-commits mailing list