Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Delta Between Two Patch Sets: ext/content.js

Issue 5056848617013248: Issue 1706 - Move first-run page to adblockplusui repository (Closed)
Left Patch Set: Created Jan. 6, 2015, 10:39 p.m.
Right Patch Set: Export variables differently in common.js Created Jan. 7, 2015, 6:58 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
Left: Side by side diff | Download
Right: Side by side diff | Download
« no previous file with change/comment | « ext/common.js ('k') | lib/main.js » ('j') | no next file with change/comment »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
LEFTRIGHT
1 /* 1 /*
2 * This file is part of Adblock Plus <http://adblockplus.org/>, 2 * This file is part of Adblock Plus <http://adblockplus.org/>,
3 * Copyright (C) 2006-2014 Eyeo GmbH 3 * Copyright (C) 2006-2014 Eyeo GmbH
4 * 4 *
5 * Adblock Plus is free software: you can redistribute it and/or modify 5 * Adblock Plus is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License version 3 as 6 * it under the terms of the GNU General Public License version 3 as
7 * published by the Free Software Foundation. 7 * published by the Free Software Foundation.
8 * 8 *
9 * Adblock Plus is distributed in the hope that it will be useful, 9 * Adblock Plus is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 var replacement = args[index - 1]; 75 var replacement = args[index - 1];
76 if (typeof replacement === "undefined") 76 if (typeof replacement === "undefined")
77 continue; 77 continue;
78 78
79 text = text.split("$" + key + "$").join(replacement); 79 text = text.split("$" + key + "$").join(replacement);
80 } 80 }
81 return text; 81 return text;
82 } 82 }
83 83
84 return { 84 return {
85 noSpecialMessages: true,
86
87 getMessage: function(key, args) 85 getMessage: function(key, args)
88 { 86 {
89 try{ 87 try{
90 var message = getI18nMessage(key); 88 var message = getI18nMessage(key);
91 return getText(message, args); 89 return getText(message, args);
92 } 90 }
93 catch(e) 91 catch(e)
94 { 92 {
95 Cu.reportError(e); 93 // Don't report errors for special strings, these are expected to be
96 return "Missing translation: " + key; 94 // missing.
95 if (key[0] != "@")
96 Cu.reportError(e);
97 return "";
97 } 98 }
98 } 99 }
99 }; 100 };
100 })(); 101 })();
101 })(this); 102 })(this);
LEFTRIGHT

Powered by Google App Engine
This is Rietveld