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

Side by Side Diff: ui/ozone/platform/drm/ozone_platform_gbm.cc

Issue 2420253002: Rename shell namespace to service_manager (Closed)
Patch Set: . Created 4 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 unified diff | Download patch
« no previous file with comments | « ui/ozone/platform/drm/gpu/drm_thread_proxy.h ('k') | ui/ozone/public/ozone_platform.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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "ui/ozone/platform/drm/ozone_platform_gbm.h" 5 #include "ui/ozone/platform/drm/ozone_platform_gbm.h"
6 6
7 #include <dlfcn.h> 7 #include <dlfcn.h>
8 #include <fcntl.h> 8 #include <fcntl.h>
9 #include <gbm.h> 9 #include <gbm.h>
10 #include <stdlib.h> 10 #include <stdlib.h>
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 // symbols in the libglapi library however it does not explicitly link against 73 // symbols in the libglapi library however it does not explicitly link against
74 // it. That caused linkage errors when running an application that does not 74 // it. That caused linkage errors when running an application that does not
75 // explicitly link against libglapi. 75 // explicitly link against libglapi.
76 void* glapi_lib_; 76 void* glapi_lib_;
77 77
78 DISALLOW_COPY_AND_ASSIGN(GlApiLoader); 78 DISALLOW_COPY_AND_ASSIGN(GlApiLoader);
79 }; 79 };
80 80
81 class OzonePlatformGbm 81 class OzonePlatformGbm
82 : public OzonePlatform, 82 : public OzonePlatform,
83 public shell::InterfaceFactory<ozone::mojom::DeviceCursor> { 83 public service_manager::InterfaceFactory<ozone::mojom::DeviceCursor> {
84 public: 84 public:
85 OzonePlatformGbm() : using_mojo_(false), single_process_(false) {} 85 OzonePlatformGbm() : using_mojo_(false), single_process_(false) {}
86 ~OzonePlatformGbm() override {} 86 ~OzonePlatformGbm() override {}
87 87
88 // OzonePlatform: 88 // OzonePlatform:
89 ui::SurfaceFactoryOzone* GetSurfaceFactoryOzone() override { 89 ui::SurfaceFactoryOzone* GetSurfaceFactoryOzone() override {
90 return surface_factory_.get(); 90 return surface_factory_.get();
91 } 91 }
92 OverlayManagerOzone* GetOverlayManager() override { 92 OverlayManagerOzone* GetOverlayManager() override {
93 return overlay_manager_.get(); 93 return overlay_manager_.get();
94 } 94 }
95 CursorFactoryOzone* GetCursorFactoryOzone() override { 95 CursorFactoryOzone* GetCursorFactoryOzone() override {
96 return cursor_factory_ozone_.get(); 96 return cursor_factory_ozone_.get();
97 } 97 }
98 InputController* GetInputController() override { 98 InputController* GetInputController() override {
99 return event_factory_ozone_->input_controller(); 99 return event_factory_ozone_->input_controller();
100 } 100 }
101 IPC::MessageFilter* GetGpuMessageFilter() override { 101 IPC::MessageFilter* GetGpuMessageFilter() override {
102 return gpu_message_filter_.get(); 102 return gpu_message_filter_.get();
103 } 103 }
104 GpuPlatformSupportHost* GetGpuPlatformSupportHost() override { 104 GpuPlatformSupportHost* GetGpuPlatformSupportHost() override {
105 return gpu_platform_support_host_.get(); 105 return gpu_platform_support_host_.get();
106 } 106 }
107 std::unique_ptr<SystemInputInjector> CreateSystemInputInjector() override { 107 std::unique_ptr<SystemInputInjector> CreateSystemInputInjector() override {
108 return event_factory_ozone_->CreateSystemInputInjector(); 108 return event_factory_ozone_->CreateSystemInputInjector();
109 } 109 }
110 void AddInterfaces(shell::InterfaceRegistry* registry) override { 110 void AddInterfaces(service_manager::InterfaceRegistry* registry) override {
111 registry->AddInterface<ozone::mojom::DeviceCursor>(this); 111 registry->AddInterface<ozone::mojom::DeviceCursor>(this);
112 } 112 }
113 // shell::InterfaceFactory<ozone::mojom::DeviceCursor> implementation. 113 // service_manager::InterfaceFactory<ozone::mojom::DeviceCursor>:
114 void Create(const shell::Identity& remote_identity, 114 void Create(const service_manager::Identity& remote_identity,
115 ozone::mojom::DeviceCursorRequest request) override { 115 ozone::mojom::DeviceCursorRequest request) override {
116 if (drm_thread_proxy_) 116 if (drm_thread_proxy_)
117 drm_thread_proxy_->AddBinding(std::move(request)); 117 drm_thread_proxy_->AddBinding(std::move(request));
118 else 118 else
119 pending_cursor_requests_.push_back(std::move(request)); 119 pending_cursor_requests_.push_back(std::move(request));
120 } 120 }
121 std::unique_ptr<PlatformWindow> CreatePlatformWindow( 121 std::unique_ptr<PlatformWindow> CreatePlatformWindow(
122 PlatformWindowDelegate* delegate, 122 PlatformWindowDelegate* delegate,
123 const gfx::Rect& bounds) override { 123 const gfx::Rect& bounds) override {
124 GpuThreadAdapter* adapter = gpu_platform_support_host_.get(); 124 GpuThreadAdapter* adapter = gpu_platform_support_host_.get();
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
274 DISALLOW_COPY_AND_ASSIGN(OzonePlatformGbm); 274 DISALLOW_COPY_AND_ASSIGN(OzonePlatformGbm);
275 }; 275 };
276 276
277 } // namespace 277 } // namespace
278 278
279 OzonePlatform* CreateOzonePlatformGbm() { 279 OzonePlatform* CreateOzonePlatformGbm() {
280 return new OzonePlatformGbm; 280 return new OzonePlatformGbm;
281 } 281 }
282 282
283 } // namespace ui 283 } // namespace ui
OLDNEW
« no previous file with comments | « ui/ozone/platform/drm/gpu/drm_thread_proxy.h ('k') | ui/ozone/public/ozone_platform.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698