Index: lib/utils.js |
=================================================================== |
--- a/lib/utils.js |
+++ b/lib/utils.js |
@@ -1,6 +1,6 @@ |
/* |
* This file is part of Adblock Plus <http://adblockplus.org/>, |
- * Copyright (C) 2006-2013 Eyeo GmbH |
+ * Copyright (C) 2006-2014 Eyeo GmbH |
* |
* Adblock Plus is free software: you can redistribute it and/or modify |
* it under the terms of the GNU General Public License version 3 as |
@@ -21,7 +21,10 @@ |
systemPrincipal: null, |
getString: function(id) |
{ |
- return id; |
+ if (typeof ext !== "undefined" && "i18n" in ext) |
+ return ext.i18n.getMessage("global_" + id); |
+ else |
+ return id; |
}, |
// This function can take additional parameters. Second paramater will be |
@@ -44,7 +47,7 @@ |
let queue = runAsyncQueue; |
runAsyncQueue = null; |
- for each (let callback in queue) |
+ for (let callback of queue) |
{ |
try |
{ |
@@ -138,5 +141,9 @@ |
var Prefs = require("prefs").Prefs; |
var docLink = Prefs.documentation_link; |
return docLink.replace(/%LINK%/g, linkID).replace(/%LANG%/g, Utils.appLocale); |
+ }, |
+ |
+ yield: function() |
+ { |
} |
}; |