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

Unified Diff: chrome/renderer/resources/extension_process_bindings.js

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/resources/extension_process_bindings.js
diff --git a/chrome/renderer/resources/extension_process_bindings.js b/chrome/renderer/resources/extension_process_bindings.js
index 6dfa25a419162baad04a3ceb6c0eab1bfcdac46a..0ac0be428a8e2fb502cc77a18fb7db89c134b565 100644
--- a/chrome/renderer/resources/extension_process_bindings.js
+++ b/chrome/renderer/resources/extension_process_bindings.js
@@ -2,11 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-// -----------------------------------------------------------------------------
-// NOTE: If you change this file you need to touch renderer_resources.grd to
-// have your change take effect.
-// -----------------------------------------------------------------------------
-
// This script contains privileged chrome extension related javascript APIs.
// It is loaded by pages whose URL has the chrome-extension protocol.
@@ -221,11 +216,7 @@ var chrome = chrome || {};
}
chromeHidden.onLoad.addListener(function (extensionId) {
- chrome.extension = new chrome.Extension(extensionId);
-
- // TODO(mpcomplete): chrome.self is deprecated. Remove it at 1.0.
- // http://code.google.com/p/chromium/issues/detail?id=16356
- chrome.self = chrome.extension;
+ chrome.initExtension(extensionId);
// |apiFunctions| is a hash of name -> object that stores the
// name & definition of the apiFunction. Custom handling of api functions
@@ -297,7 +288,7 @@ var chrome = chrome || {};
name = connectInfo.name || name;
}
var portId = OpenChannelToTab(
- tabId, chrome.extension.id_, name);
+ tabId, chromeHidden.extensionId, name);
return chromeHidden.Port.createPort(portId, name);
}
« no previous file with comments | « chrome/renderer/resources/event_bindings.js ('k') | chrome/renderer/resources/renderer_extension_bindings.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698