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

Unified Diff: chrome/ext/background.js

Issue 29370947: Issue 3138 - Improve how context menu "block element" handles iframes (Closed)
Patch Set: Addressed feedback Created Jan. 12, 2017, 7:14 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | composer.postload.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/ext/background.js
diff --git a/chrome/ext/background.js b/chrome/ext/background.js
index 4681ec08bb0fbf200b337c74cd8d33e09d754c26..26e4a5afd085395f293a8fc4d695a90c16d87fca 100644
--- a/chrome/ext/background.js
+++ b/chrome/ext/background.js
@@ -46,9 +46,12 @@
return frame.url;
}
},
- sendMessage: function(message, responseCallback)
+ sendMessage: function(message, responseCallback, frameId)
{
- chrome.tabs.sendMessage(this.id, message, responseCallback);
+ let options = {};
+ if (typeof frameId != "undefined")
+ options.frameId = frameId;
+ chrome.tabs.sendMessage(this.id, message, options, responseCallback);
}
};
@@ -328,7 +331,7 @@
contexts: item.contexts,
onclick: function(info, tab)
{
- item.onclick(new Page(tab));
+ item.onclick(new Page(tab), info);
}
});
});
« no previous file with comments | « no previous file | composer.postload.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld