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

Side by Side Diff: lib/child/objectTabs.js

Issue 29329884: Issue 3224 - Unbreak filter assistant (Closed)
Patch Set: Rebased Created Nov. 12, 2015, 3:10 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 <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-2015 Eyeo GmbH 3 * Copyright (C) 2006-2015 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 295 matching lines...) Expand 10 before | Expand all | Expand 10 after
306 rect.right += relLeft; 306 rect.right += relLeft;
307 rect.top += relTop; 307 rect.top += relTop;
308 rect.bottom += relTop; 308 rect.bottom += relTop;
309 } 309 }
310 310
311 return rect; 311 return rect;
312 }, 312 },
313 313
314 doBlock: function() 314 doBlock: function()
315 { 315 {
316 // TODO: Store this.currentElement for the filter assistant 316 let {storeNodes} = require("child/contentPolicy");
317 sendAsyncMessage("AdblockPlus:BlockItem", this.objtabElement.nodeData); 317 let nodesID = storeNodes([this.currentElement]);
318 sendAsyncMessage("AdblockPlus:BlockItem", {
319 request: this.objtabElement.nodeData,
320 nodesID
321 });
318 }, 322 },
319 323
320 /** 324 /**
321 * Called whenever a timer fires. 325 * Called whenever a timer fires.
322 * @param {nsISupport} subject 326 * @param {nsISupport} subject
323 * @param {string} topic 327 * @param {string} topic
324 * @param {string} data 328 * @param {string} data
325 */ 329 */
326 observe: function(subject, topic, data) 330 observe: function(subject, topic, data)
327 { 331 {
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
385 event.stopPropagation(); 389 event.stopPropagation();
386 390
387 objTabs.doBlock(); 391 objTabs.doBlock();
388 } 392 }
389 else if (event.type == "mouseover") 393 else if (event.type == "mouseover")
390 objTabs.showTabFor(objTabs.currentElement); 394 objTabs.showTabFor(objTabs.currentElement);
391 else if (event.type == "mouseout") 395 else if (event.type == "mouseout")
392 objTabs.hideTabFor(objTabs.currentElement); 396 objTabs.hideTabFor(objTabs.currentElement);
393 } 397 }
394 exports.objectMouseEventHander = objectMouseEventHander; 398 exports.objectMouseEventHander = objectMouseEventHander;
OLDNEW

Powered by Google App Engine
This is Rietveld