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

Side by Side Diff: stats.js

Issue 16067002: Added Safari Support (Closed)
Patch Set: Removed absolute URL fix for Safari (this is done by the buildtools now), introduced browser specif… Created Oct. 31, 2013, 10:50 a.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
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
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details. 12 * GNU General Public License for more details.
13 * 13 *
14 * You should have received a copy of the GNU General Public License 14 * You should have received a copy of the GNU General Public License
15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>. 15 * along with Adblock Plus. If not, see <http://www.gnu.org/licenses/>.
16 */ 16 */
17 17
18 (function() 18 (function()
19 { 19 {
20 var backgroundPage = chrome.extension.getBackgroundPage(); 20 var backgroundPage = ext.backgroundPage.getWindow();
21 var require = backgroundPage.require; 21 var require = backgroundPage.require;
22 var getStats = require("stats").getStats; 22 var getStats = require("stats").getStats;
23 var FilterNotifier = require("filterNotifier").FilterNotifier; 23 var FilterNotifier = require("filterNotifier").FilterNotifier;
24 24
25 var currentTabId; 25 var currentTabId;
26 var shareURL = "https://adblockplus.org/"; 26 var shareURL = "https://adblockplus.org/";
27 27
28 var messageMark = {}; 28 var messageMark = {};
29 var shareLinks = { 29 var shareLinks = {
30 facebook: ["https://www.facebook.com/dialog/feed", { 30 facebook: ["https://www.facebook.com/dialog/feed", {
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
126 else 126 else
127 blocked = i18n.getMessage("stats_over", (9000).toLocaleString()); 127 blocked = i18n.getMessage("stats_over", (9000).toLocaleString());
128 128
129 var url = createShareLink(ev.target.dataset.social, blocked); 129 var url = createShareLink(ev.target.dataset.social, blocked);
130 chrome.tabs.create({url: url}); 130 chrome.tabs.create({url: url});
131 } 131 }
132 132
133 document.addEventListener("DOMContentLoaded", onLoad, false); 133 document.addEventListener("DOMContentLoaded", onLoad, false);
134 window.addEventListener("unload", onUnload, false); 134 window.addEventListener("unload", onUnload, false);
135 })(); 135 })();
OLDNEW
« _locales/en_US/messages.json ('K') | « safari/content.js ('k') | utils.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld