| Index: ext/content.js |
| diff --git a/ext/content.js b/ext/content.js |
| index 3b84e05286c6a3261f8b3f7aea09d00ba69df177..b2b956a1b11d8908e088383db34e699f263e4789 100644 |
| --- a/ext/content.js |
| +++ b/ext/content.js |
| @@ -79,65 +79,4 @@ |
| } |
| }; |
| - /* i18n */ |
| - global.ext.i18n = (function() |
| - { |
| - var pageName = location.pathname.replace(/.*\//, "").replace(/\..*?$/, ""); |
| - |
| - // Randomize URI to work around bug 719376 |
| - var stringBundle = Services.strings.createBundle("chrome://adblockplus/locale/" + pageName + |
| - ".properties?" + Math.random()); |
| - |
| - function getI18nMessage(key) |
| - { |
| - return { |
| - "message": stringBundle.GetStringFromName(key) |
| - }; |
| - } |
| - |
| - function getText(message, args) |
| - { |
| - var text = message.message; |
| - var placeholders = message.placeholders; |
| - |
| - if (!args || !placeholders) |
| - return text; |
| - |
| - for (var key in placeholders) |
| - { |
| - var content = placeholders[key].content; |
| - if (!content) |
| - continue; |
| - |
| - var index = parseInt(content.slice(1), 10); |
| - if (isNaN(index)) |
| - continue; |
| - |
| - var replacement = args[index - 1]; |
| - if (typeof replacement === "undefined") |
| - continue; |
| - |
| - text = text.split("$" + key + "$").join(replacement); |
| - } |
| - return text; |
| - } |
| - |
| - return { |
| - getMessage: function(key, args) |
| - { |
| - try{ |
| - var message = getI18nMessage(key); |
| - return getText(message, args); |
| - } |
| - catch(e) |
| - { |
| - // Don't report errors for special strings, these are expected to be |
| - // missing. |
| - if (key[0] != "@") |
| - Cu.reportError(e); |
| - return ""; |
| - } |
| - } |
| - }; |
| - })(); |
| })(this); |