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

Side by Side Diff: chrome/content/ui/sendReport.js

Issue 11015083: Merge labels and access keys into one string in locales (Closed)
Patch Set: Created July 9, 2013, 12:03 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | lib/ui.js » ('j') | lib/ui.js » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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-2013 Eyeo GmbH 3 * Copyright (C) 2006-2013 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 1183 matching lines...) Expand 10 before | Expand all | Expand 10 after
1194 } 1194 }
1195 1195
1196 function updateNextButton() 1196 function updateNextButton()
1197 { 1197 {
1198 let nextButton = document.documentElement.getButton("next"); 1198 let nextButton = document.documentElement.getButton("next");
1199 if (!nextButton) 1199 if (!nextButton)
1200 return; 1200 return;
1201 1201
1202 if (document.documentElement.currentPage.id == "commentPage") 1202 if (document.documentElement.currentPage.id == "commentPage")
1203 { 1203 {
1204 if (!nextButton.hasAttribute("_origLabel")) 1204 if (!("_origLabel" in nextButton))
1205 { 1205 {
1206 nextButton._origLabel = nextButton.label; 1206 nextButton._origLabel = nextButton.label;
1207 nextButton._origAccessKey = nextButton.accessKey; 1207 nextButton._origAccessKey = nextButton.accessKey;
1208 [nextButton.label, nextButton.accessKey] = Utils.splitLabel(document.docum entElement.getAttribute("sendbuttonlabel")); 1208 [nextButton.label, nextButton.accessKey] = Utils.splitLabel(document.docum entElement.getAttribute("sendbuttonlabel"));
1209 } 1209 }
1210 } 1210 }
1211 else 1211 else
1212 { 1212 {
1213 if (nextButton.hasAttribute("_origLabel")) 1213 if ("_origLabel" in nextButton)
1214 { 1214 {
1215 nextButton.label = nextButton._origLabel; 1215 nextButton.label = nextButton._origLabel;
1216 nextButton.accessKey = nextButton._origAccessKey; 1216 nextButton.accessKey = nextButton._origAccessKey;
1217 delete nextButton._origLabel; 1217 delete nextButton._origLabel;
1218 delete nextButton._origAccessKey; 1218 delete nextButton._origAccessKey;
1219 } 1219 }
1220 } 1220 }
1221 } 1221 }
1222 1222
1223 function initDataCollectorPage() 1223 function initDataCollectorPage()
(...skipping 336 matching lines...) Expand 10 before | Expand all | Expand 10 after
1560 1560
1561 function censorURL(url) 1561 function censorURL(url)
1562 { 1562 {
1563 return url.replace(/([?;&\/#][^?;&\/#]+?=)[^?;&\/#]+/g, "$1*"); 1563 return url.replace(/([?;&\/#][^?;&\/#]+?=)[^?;&\/#]+/g, "$1*");
1564 } 1564 }
1565 1565
1566 function encodeHTML(str) 1566 function encodeHTML(str)
1567 { 1567 {
1568 return str.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;"). replace(/"/g, "&quot;"); 1568 return str.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;"). replace(/"/g, "&quot;");
1569 } 1569 }
OLDNEW
« no previous file with comments | « no previous file | lib/ui.js » ('j') | lib/ui.js » ('J')

Powered by Google App Engine
This is Rietveld