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

Side by Side Diff: ext/common.js

Issue 29397620: Issue 5055 - Update adblockpluscore dependency to revision d0715e99bd3b and adblockplusui to 8ceaab… (Closed) Base URL: https://hg.adblockplus.org/adblockplus
Patch Set: Show effective selectors in blockable items Created March 29, 2017, 1:27 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 | « dependencies ('k') | lib/child/elemHideEmulation.js » ('j') | no next file with comments »
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 <https://adblockplus.org/>, 2 * This file is part of Adblock Plus <https://adblockplus.org/>,
3 * Copyright (C) 2006-2017 eyeo GmbH 3 * Copyright (C) 2006-2017 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 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 get: () => wrapFrames(frames.slice(1)) 43 get: () => wrapFrames(frames.slice(1))
44 }); 44 });
45 45
46 return frames; 46 return frames;
47 } 47 }
48 48
49 var EventTarget = global.ext._EventTarget = function(port, windowID) 49 var EventTarget = global.ext._EventTarget = function(port, windowID)
50 { 50 {
51 this._port = port; 51 this._port = port;
52 this._windowID = windowID; 52 this._windowID = windowID;
53 this.addListener((payload, sender, resolve) =>
54 {
55 if (payload.type)
56 {
57 let result = this._port._dispatch(payload.type, payload, sender);
58 if (typeof result != "undefined")
59 resolve(result);
60 }
61 });
53 }; 62 };
54 EventTarget.prototype = { 63 EventTarget.prototype = {
55 addListener: function(listener) 64 addListener: function(listener)
56 { 65 {
57 var wrapper = (message, sender) => 66 var wrapper = (message, sender) =>
58 { 67 {
59 if (this._windowID && this._windowID != message.targetID) 68 if (this._windowID && this._windowID != message.targetID)
60 return undefined; 69 return undefined;
61 70
62 return new Promise((resolve, reject) => 71 return new Promise((resolve, reject) =>
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
106 if (key[0] != "@") 115 if (key[0] != "@")
107 Cu.reportError(e); 116 Cu.reportError(e);
108 return ""; 117 return "";
109 } 118 }
110 } 119 }
111 }; 120 };
112 121
113 if (typeof exports == "object") 122 if (typeof exports == "object")
114 exports = global.ext; 123 exports = global.ext;
115 })(this); 124 })(this);
OLDNEW
« no previous file with comments | « dependencies ('k') | lib/child/elemHideEmulation.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld