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

Delta Between Two Patch Sets: block.js

Issue 16067002: Added Safari Support (Closed)
Left Patch Set: Made description for Safari long again. The 100 char limit given by the extension builder doesn't a… Created Oct. 31, 2013, 2:12 p.m.
Right Patch Set: Bugfixes Created Nov. 15, 2013, 8:58 a.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 | « background.js ('k') | chrome/background.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-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 11 matching lines...) Expand all
22 window.addEventListener("dragstart", onDragStart, false); 22 window.addEventListener("dragstart", onDragStart, false);
23 window.addEventListener("drag", onDrag, false); 23 window.addEventListener("drag", onDrag, false);
24 window.addEventListener("dragend", onDragEnd, false); 24 window.addEventListener("dragend", onDragEnd, false);
25 25
26 $("#addButton").click(addFilters); 26 $("#addButton").click(addFilters);
27 $("#cancelButton").click(closeDialog.bind(null, false)); 27 $("#cancelButton").click(closeDialog.bind(null, false));
28 28
29 // Apply jQuery UI styles 29 // Apply jQuery UI styles
30 $("button").button(); 30 $("button").button();
31 31
32 ext.backgroundPage.sendMessage({ 32 ext.backgroundPage.sendMessage(
33 {
33 type: "forward", 34 type: "forward",
34 payload: 35 payload:
35 { 36 {
36 type: "clickhide-init", 37 type: "clickhide-init",
37 width: Math.max(document.body.offsetWidth || document.body.scrollWidth), 38 width: Math.max(document.body.offsetWidth || document.body.scrollWidth),
38 height: Math.max(document.body.offsetHeight || document.body.scrollHeight) 39 height: Math.max(document.body.offsetHeight || document.body.scrollHeight)
39 } 40 }
40 }, 41 },
41 function(response) { 42 function(response)
43 {
42 document.getElementById("filters").value = response.filters.join("\n"); 44 document.getElementById("filters").value = response.filters.join("\n");
43 }); 45 });
44 46
45 document.getElementById("filters").focus(); 47 document.getElementById("filters").focus();
46 } 48 }
47 $(init); 49 $(init);
48 50
49 function onKeyDown(event) 51 function onKeyDown(event)
50 { 52 {
51 if (event.keyCode == 27) 53 if (event.keyCode == 27)
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 ); 116 );
115 dragCoords = [event.screenX, event.screenY]; 117 dragCoords = [event.screenX, event.screenY];
116 } 118 }
117 } 119 }
118 120
119 function onDragEnd(event) 121 function onDragEnd(event)
120 { 122 {
121 onDrag(event); 123 onDrag(event);
122 dragCoords = null; 124 dragCoords = null;
123 } 125 }
LEFTRIGHT

Powered by Google App Engine
This is Rietveld