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

Delta Between Two Patch Sets: chrome/ext/popup.js

Issue 29374674: Issue 4864 - Start using ESLint for adblockpluschrome (Closed)
Left Patch Set: Update Cu.import use to correspond with adblockpluscore changes, removed unused utils.js file Created March 8, 2017, 12:26 p.m.
Right Patch Set: Use .includes again Created March 31, 2017, 8:37 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 | « chrome/ext/devtools.js ('k') | composer.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 "use strict"; 1 "use strict";
2 2
3 let ext; 3 (function()
4
5 { 4 {
6 const backgroundPage = chrome.extension.getBackgroundPage(); 5 const backgroundPage = chrome.extension.getBackgroundPage();
7 ext = Object.create(backgroundPage.ext); 6 window.ext = Object.create(backgroundPage.ext);
8 7
9 ext.closePopup = () => 8 window.ext.closePopup = () =>
10 { 9 {
11 window.close(); 10 window.close();
12 }; 11 };
13 12
14 // We have to override ext.backgroundPage, because in order 13 // We have to override ext.backgroundPage, because in order
15 // to send messages the local "chrome" namespace must be used. 14 // to send messages the local "chrome" namespace must be used.
16 ext.backgroundPage = { 15 window.ext.backgroundPage = {
17 sendMessage: chrome.runtime.sendMessage, 16 sendMessage: chrome.runtime.sendMessage,
18 17
19 getWindow() 18 getWindow()
20 { 19 {
21 return backgroundPage; 20 return backgroundPage;
22 } 21 }
23 }; 22 };
24 } 23 }());
LEFTRIGHT

Powered by Google App Engine
This is Rietveld