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

Unified Diff: components/web_view/public/cpp/web_view.cc

Issue 1635603002: Make use of CreateInterfacePtrAndBind() where appropriate (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tweaks Created 4 years, 11 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: components/web_view/public/cpp/web_view.cc
diff --git a/components/web_view/public/cpp/web_view.cc b/components/web_view/public/cpp/web_view.cc
index 85af0f483e0e3e8c1f76cbf476591ed87d974b95..647096083e1b4353e39875e9ecb41bf7c7db89d3 100644
--- a/components/web_view/public/cpp/web_view.cc
+++ b/components/web_view/public/cpp/web_view.cc
@@ -24,14 +24,10 @@ WebView::WebView(mojom::WebViewClient* client) : binding_(client) {}
WebView::~WebView() {}
void WebView::Init(mojo::ApplicationImpl* app, mus::Window* window) {
- mojom::WebViewClientPtr client;
- mojo::InterfaceRequest<mojom::WebViewClient> client_request =
- GetProxy(&client);
- binding_.Bind(std::move(client_request));
-
mojom::WebViewFactoryPtr factory;
app->ConnectToService("mojo:web_view", &factory);
- factory->CreateWebView(std::move(client), GetProxy(&web_view_));
+ factory->CreateWebView(binding_.CreateInterfacePtrAndBind(),
+ GetProxy(&web_view_));
mus::mojom::WindowTreeClientPtr window_tree_client;
web_view_->GetWindowTreeClient(GetProxy(&window_tree_client));
« no previous file with comments | « components/web_view/frame_devtools_agent.cc ('k') | content/child/navigator_connect/service_port_provider.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698