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

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

Issue 2676553003: mus: Fix creating the factory for window-tree-client in renderer. (Closed)
Patch Set: . Created 3 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | content/renderer/mus/renderer_window_tree_client.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/mus/render_widget_window_tree_client_factory.h" 5 #include "content/renderer/mus/render_widget_window_tree_client_factory.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 13 matching lines...) Expand all
24 #include "services/ui/public/interfaces/window_tree.mojom.h" 24 #include "services/ui/public/interfaces/window_tree.mojom.h"
25 #include "url/gurl.h" 25 #include "url/gurl.h"
26 26
27 namespace content { 27 namespace content {
28 28
29 namespace { 29 namespace {
30 30
31 void BindMusConnectionOnMainThread( 31 void BindMusConnectionOnMainThread(
32 uint32_t routing_id, 32 uint32_t routing_id,
33 ui::mojom::WindowTreeClientRequest request) { 33 ui::mojom::WindowTreeClientRequest request) {
34 RendererWindowTreeClient::CreateIfNecessary(routing_id);
34 RendererWindowTreeClient::Get(routing_id)->Bind(std::move(request)); 35 RendererWindowTreeClient::Get(routing_id)->Bind(std::move(request));
35 } 36 }
36 37
37 // This object's lifetime is managed by ServiceManagerConnection because it's a 38 // This object's lifetime is managed by ServiceManagerConnection because it's a
38 // registered with it. 39 // registered with it.
39 class RenderWidgetWindowTreeClientFactoryImpl 40 class RenderWidgetWindowTreeClientFactoryImpl
40 : public ConnectionFilter, 41 : public ConnectionFilter,
41 public mojom::RenderWidgetWindowTreeClientFactory { 42 public mojom::RenderWidgetWindowTreeClientFactory {
42 public: 43 public:
43 RenderWidgetWindowTreeClientFactoryImpl() : weak_factory_(this) { 44 RenderWidgetWindowTreeClientFactoryImpl() : weak_factory_(this) {
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 81
81 } // namespace 82 } // namespace
82 83
83 void CreateRenderWidgetWindowTreeClientFactory( 84 void CreateRenderWidgetWindowTreeClientFactory(
84 ServiceManagerConnection* connection) { 85 ServiceManagerConnection* connection) {
85 connection->AddConnectionFilter( 86 connection->AddConnectionFilter(
86 base::MakeUnique<RenderWidgetWindowTreeClientFactoryImpl>()); 87 base::MakeUnique<RenderWidgetWindowTreeClientFactoryImpl>());
87 } 88 }
88 89
89 } // namespace content 90 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | content/renderer/mus/renderer_window_tree_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698