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

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

Issue 11533106: Prepared adblockplus for Safari (Closed)
Patch Set: Prepared adblockplus for Safari Created Sept. 2, 2013, 6:29 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
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 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 46
47 function onDOMLoaded() 47 function onDOMLoaded()
48 { 48 {
49 // Show warning if data corruption was detected 49 // Show warning if data corruption was detected
50 if (typeof backgroundPage != "undefined" && backgroundPage.seenDataCorruptio n) 50 if (typeof backgroundPage != "undefined" && backgroundPage.seenDataCorruptio n)
51 { 51 {
52 E("dataCorruptionWarning").removeAttribute("hidden"); 52 E("dataCorruptionWarning").removeAttribute("hidden");
53 setLinks("dataCorruptionWarning", Utils.getDocLink("knownIssuesChrome_filt erstorage")); 53 setLinks("dataCorruptionWarning", Utils.getDocLink("knownIssuesChrome_filt erstorage"));
54 } 54 }
55 55
56 // Show warning if Safari < 6
57 var info = require('info');
58 if (info.platform == "safari" && info.platformVersion.split(".") < [6])
59 E("legacySafariWarning").removeAttribute("hidden");
60
56 // Set up URL 61 // Set up URL
57 setLinks("acceptableAdsExplanation", Utils.getDocLink("acceptable_ads_criter ia"), openFilters); 62 setLinks("acceptableAdsExplanation", Utils.getDocLink("acceptable_ads_criter ia"), openFilters);
58 63
59 shade = E("shade"); 64 shade = E("shade");
60 shade.addEventListener("mouseover", scrollPage, false); 65 shade.addEventListener("mouseover", scrollPage, false);
61 shade.addEventListener("mouseout", stopScroll, false); 66 shade.addEventListener("mouseout", stopScroll, false);
62 67
63 // Set up feature buttons linked to subscriptions 68 // Set up feature buttons linked to subscriptions
64 featureSubscriptions.forEach(setToggleSubscriptionButton); 69 featureSubscriptions.forEach(setToggleSubscriptionButton);
65 var filterListener = function(action) 70 var filterListener = function(action)
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 { 262 {
258 var button = E("toggle-" + feature); 263 var button = E("toggle-" + feature);
259 if (isEnabled) 264 if (isEnabled)
260 button.classList.remove("off"); 265 button.classList.remove("off");
261 else 266 else
262 button.classList.add("off"); 267 button.classList.add("off");
263 } 268 }
264 269
265 document.addEventListener("DOMContentLoaded", onDOMLoaded, false); 270 document.addEventListener("DOMContentLoaded", onDOMLoaded, false);
266 })(); 271 })();
OLDNEW

Powered by Google App Engine
This is Rietveld