diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-09-09 15:41:15 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-09-09 15:41:15 +0200 |
commit | 7c9b62ee0a2253858499054321b5a57b3dd19f11 (patch) | |
tree | 8f3e14e1bced6211ffe17f2eb65ae6038b56b5f1 | |
parent | a744d76655f08a2812270da0c459126428c5786d (diff) | |
download | uxp-7c9b62ee0a2253858499054321b5a57b3dd19f11.tar.gz |
Add findbar.termPerTab
Allow the pref to switch between global search term and per-tab search term
-rw-r--r-- | modules/libpref/init/all.js | 1 | ||||
-rw-r--r-- | toolkit/content/widgets/findbar.xml | 5 |
2 files changed, 5 insertions, 1 deletions
diff --git a/modules/libpref/init/all.js b/modules/libpref/init/all.js index 1eee30210d..0ec5f15961 100644 --- a/modules/libpref/init/all.js +++ b/modules/libpref/init/all.js @@ -908,6 +908,7 @@ pref("findbar.highlightAll", false); pref("findbar.modalHighlight", false); pref("findbar.entireword", false); pref("findbar.iteratorTimeout", 100); +pref("findbar.termPerTab", false); // use Mac OS X Appearance panel text smoothing setting when rendering text, disabled by default pref("gfx.use_text_smoothing_setting", false); diff --git a/toolkit/content/widgets/findbar.xml b/toolkit/content/widgets/findbar.xml index b92fb1d051..c312a6a25a 100644 --- a/toolkit/content/widgets/findbar.xml +++ b/toolkit/content/widgets/findbar.xml @@ -282,6 +282,7 @@ return this._browser; ]]></getter> <setter><![CDATA[ + let prefsvc = this._prefsvc; if (this._browser) { if (this._browser.messageManager) { this._browser.messageManager.removeMessageListener("Findbar:Keypress", this); @@ -300,7 +301,9 @@ this._browser.messageManager.addMessageListener("Findbar:Mouseup", this); this._browser.finder.addResultListener(this); - this._findField.value = this._browser._lastSearchString; + if (prefsvc.getBoolPref("findbar.termPerTab") == true) { + this._findField.value = this._browser._lastSearchString; + } } return val; ]]></setter> |