Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(338)

Unified Diff: chrome/renderer/user_script_slave.cc

Issue 262016: Implement chrome.extension.connectExternal and fix various API inconsistencies. (Closed)
Patch Set: addressed comments Created 11 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/renderer/user_script_slave.cc
diff --git a/chrome/renderer/user_script_slave.cc b/chrome/renderer/user_script_slave.cc
index 86fcc1a768e03ecf1f5834b000e2cbbc65c80bfe..f3df33cfc8793b8b3938098d25a8318a5449d66c 100644
--- a/chrome/renderer/user_script_slave.cc
+++ b/chrome/renderer/user_script_slave.cc
@@ -25,12 +25,8 @@ using WebKit::WebString;
static const char kUserScriptHead[] = "(function (unsafeWindow) {\n";
static const char kUserScriptTail[] = "\n})(window);";
-// Creates a convenient reference to a content script's parent extension.
-// TODO(mpcomplete): self.onConnect is deprecated. Remove it at 1.0.
-// http://code.google.com/p/chromium/issues/detail?id=16356
-static const char kInitExtension[] =
- "chrome.extension = new chrome.Extension('%s');"
- "chrome.self.onConnect = chrome.extension.onConnect;";
+// Sets up the chrome.extension module.
+static const char kInitExtension[] = "chrome.initExtension('%s');";
int UserScriptSlave::GetIsolatedWorldId(const std::string& extension_id) {
typedef std::map<std::string, int> IsolatedWorldMap;

Powered by Google App Engine
This is Rietveld 408576698