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

Unified Diff: chrome/browser/resources/omnibox/omnibox.js

Issue 302573002: Add a Javascript wrapper around ServiceRegistry and expose it to WebUI. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@render-view-shell
Patch Set: Created 6 years, 6 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/browser/resources/omnibox/omnibox.js
diff --git a/chrome/browser/resources/omnibox/omnibox.js b/chrome/browser/resources/omnibox/omnibox.js
index afde3e03477cd23c3b5e64fd1845d2d4b34669dc..992ad438b981ae4fc79d6cb16ea21a42c3446f79 100644
--- a/chrome/browser/resources/omnibox/omnibox.js
+++ b/chrome/browser/resources/omnibox/omnibox.js
@@ -19,7 +19,8 @@
define('main', [
'mojo/public/js/bindings/connection',
'chrome/browser/ui/webui/omnibox/omnibox.mojom',
-], function(connector, browser) {
+ 'content/public/renderer/service_registry',
+], function(connector, browser, serviceRegistry) {
'use strict';
var connection;
@@ -431,8 +432,10 @@ define('main', [
refresh();
};
- return function(handle) {
- connection = new connector.Connection(handle, OmniboxPageImpl,
- browser.OmniboxUIHandlerMojoProxy);
+ return function() {
+ connection = new connector.Connection(
+ serviceRegistry.getInterface(browser.OmniboxUIHandlerMojoProxy.NAME_),
darin (slow to review) 2014/06/21 04:44:15 I think it would be nice to avoid having to use th
Sam McNally 2014/06/24 08:45:01 Added a TODO.
+ OmniboxPageImpl,
+ browser.OmniboxUIHandlerMojoProxy);
};
});
« no previous file with comments | « no previous file | chrome/browser/ui/webui/mojo_web_ui_controller.h » ('j') | chrome/browser/ui/webui/mojo_web_ui_controller.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698