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

Side by Side Diff: content/renderer/render_widget_window_tree_client_factory.cc

Issue 1484013003: mustash: Implement basic input event routing in renderer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: The right diff Created 5 years 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 unified diff | Download patch
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/render_widget_window_tree_client_factory.h" 5 #include "content/renderer/render_widget_window_tree_client_factory.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "components/mus/public/interfaces/window_tree.mojom.h" 9 #include "components/mus/public/interfaces/window_tree.mojom.h"
10 #include "content/common/render_widget_window_tree_client_factory.mojom.h" 10 #include "content/common/render_widget_window_tree_client_factory.mojom.h"
11 #include "content/public/common/mojo_shell_connection.h" 11 #include "content/public/common/mojo_shell_connection.h"
12 #include "content/renderer/render_thread_impl.h"
12 #include "content/renderer/render_widget_mus_connection.h" 13 #include "content/renderer/render_widget_mus_connection.h"
13 #include "mojo/application/public/cpp/application_connection.h" 14 #include "mojo/application/public/cpp/application_connection.h"
15 #include "mojo/application/public/cpp/application_impl.h"
14 #include "mojo/application/public/cpp/interface_factory.h" 16 #include "mojo/application/public/cpp/interface_factory.h"
sadrul 2015/12/02 18:20:57 These includes probably aren't necessary?
Fady Samuel 2015/12/02 21:30:28 Removed.
15 #include "mojo/common/weak_binding_set.h" 17 #include "mojo/common/weak_binding_set.h"
16 #include "url/gurl.h" 18 #include "url/gurl.h"
17 19
18 namespace content { 20 namespace content {
19 21
20 namespace { 22 namespace {
21 23
22 // This object's lifetime is managed by MojoShellConnection because it's a 24 // This object's lifetime is managed by MojoShellConnection because it's a
23 // MojoShellConnection::Listener. 25 // MojoShellConnection::Listener.
24 class RenderWidgetWindowTreeClientFactoryImpl 26 class RenderWidgetWindowTreeClientFactoryImpl
(...skipping 22 matching lines...) Expand all
47 request) override { 49 request) override {
48 bindings_.AddBinding(this, request.Pass()); 50 bindings_.AddBinding(this, request.Pass());
49 } 51 }
50 52
51 // mojom::RenderWidgetWindowTreeClientFactory implementation. 53 // mojom::RenderWidgetWindowTreeClientFactory implementation.
52 void CreateWindowTreeClientForRenderWidget( 54 void CreateWindowTreeClientForRenderWidget(
53 uint32_t routing_id, 55 uint32_t routing_id,
54 mojo::InterfaceRequest<mus::mojom::WindowTreeClient> request) override { 56 mojo::InterfaceRequest<mus::mojom::WindowTreeClient> request) override {
55 RenderWidgetMusConnection* connection = 57 RenderWidgetMusConnection* connection =
56 RenderWidgetMusConnection::Get(routing_id); 58 RenderWidgetMusConnection::Get(routing_id);
57 connection->Connect(request.Pass()); 59 connection->Bind(request.Pass());
58 } 60 }
59 61
60 mojo::WeakBindingSet<mojom::RenderWidgetWindowTreeClientFactory> bindings_; 62 mojo::WeakBindingSet<mojom::RenderWidgetWindowTreeClientFactory> bindings_;
61 63
62 DISALLOW_COPY_AND_ASSIGN(RenderWidgetWindowTreeClientFactoryImpl); 64 DISALLOW_COPY_AND_ASSIGN(RenderWidgetWindowTreeClientFactoryImpl);
63 }; 65 };
64 66
65 } // namespace 67 } // namespace
66 68
67 void CreateRenderWidgetWindowTreeClientFactory() { 69 void CreateRenderWidgetWindowTreeClientFactory() {
68 new RenderWidgetWindowTreeClientFactoryImpl; 70 new RenderWidgetWindowTreeClientFactoryImpl;
69 } 71 }
70 72
71 } // namespace content 73 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698