diff options
author | Moonchild <mcwerewolf@gmail.com> | 2018-06-13 23:23:40 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-13 23:23:40 +0200 |
commit | b2cb0427838a2f4f51be0366004549efb5d206fb (patch) | |
tree | 77d71fe3f5a5fec5a0885a0f71ec6b34909c9617 | |
parent | 27a19a14646f23194ecfe87530dd8d1d5b25fa57 (diff) | |
parent | 3feeaf2098ef1297f4c2fe99a01a736d7d0b10aa (diff) | |
download | UXP-b2cb0427838a2f4f51be0366004549efb5d206fb.tar UXP-b2cb0427838a2f4f51be0366004549efb5d206fb.tar.gz UXP-b2cb0427838a2f4f51be0366004549efb5d206fb.tar.lz UXP-b2cb0427838a2f4f51be0366004549efb5d206fb.tar.xz UXP-b2cb0427838a2f4f51be0366004549efb5d206fb.zip |
Merge pull request #495 from JustOff/PR_jxr_clear_accept
[PALEMOON] Remove `image/jxr` from `image.http.accept` until JPEG-XR decoder is implemented
-rw-r--r-- | application/palemoon/components/nsBrowserGlue.js | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/application/palemoon/components/nsBrowserGlue.js b/application/palemoon/components/nsBrowserGlue.js index 5910ae9c0..720d1165c 100644 --- a/application/palemoon/components/nsBrowserGlue.js +++ b/application/palemoon/components/nsBrowserGlue.js @@ -1207,7 +1207,7 @@ BrowserGlue.prototype = { }, _migrateUI: function BG__migrateUI() { - const UI_VERSION = 18; + const UI_VERSION = 19; const BROWSER_DOCURL = "chrome://browser/content/browser.xul#"; let currentUIVersion = 0; try { @@ -1426,6 +1426,22 @@ BrowserGlue.prototype = { catch (ex) {} } +#ifndef MOZ_JXR + // Until JPEG-XR decoder is implemented (UXP #144) + if (currentUIVersion < 19) { + try { + let ihaPref = "image.http.accept"; + let ihaValue = Services.prefs.getCharPref(ihaPref); + if (ihaValue.includes("image/jxr,")) { + Services.prefs.setCharPref(ihaPref, ihaValue.replace("image/jxr,", "")); + } else if (ihaValue.includes("image/jxr")) { + Services.prefs.clearUserPref(ihaPref); + } + } + catch (ex) {} + } +#endif + // Update the migration version. Services.prefs.setIntPref("browser.migration.version", UI_VERSION); }, |