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

Side by Side Diff: ui/ozone/platform/caca/ozone_platform_caca.cc

Issue 755883002: Input Injection API on Ozone (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add unit test Created 6 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
« no previous file with comments | « ui/ozone/ozone.gyp ('k') | ui/ozone/platform/dri/ozone_platform_dri.cc » ('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/caca/ozone_platform_caca.h" 5 #include "ui/ozone/platform/caca/ozone_platform_caca.h"
6 6
7 #include "ui/ozone/common/native_display_delegate_ozone.h" 7 #include "ui/ozone/common/native_display_delegate_ozone.h"
8 #include "ui/ozone/platform/caca/caca_event_source.h" 8 #include "ui/ozone/platform/caca/caca_event_source.h"
9 #include "ui/ozone/platform/caca/caca_window.h" 9 #include "ui/ozone/platform/caca/caca_window.h"
10 #include "ui/ozone/platform/caca/caca_window_manager.h" 10 #include "ui/ozone/platform/caca/caca_window_manager.h"
11 #include "ui/ozone/public/cursor_factory_ozone.h" 11 #include "ui/ozone/public/cursor_factory_ozone.h"
12 #include "ui/ozone/public/ozone_platform.h" 12 #include "ui/ozone/public/ozone_platform.h"
13 #include "ui/ozone/public/system_input_injector.h"
13 14
14 namespace ui { 15 namespace ui {
15 16
16 namespace { 17 namespace {
17 18
18 class OzonePlatformCaca : public OzonePlatform { 19 class OzonePlatformCaca : public OzonePlatform {
19 public: 20 public:
20 OzonePlatformCaca() {} 21 OzonePlatformCaca() {}
21 ~OzonePlatformCaca() override {} 22 ~OzonePlatformCaca() override {}
22 23
23 // OzonePlatform: 24 // OzonePlatform:
24 ui::SurfaceFactoryOzone* GetSurfaceFactoryOzone() override { 25 ui::SurfaceFactoryOzone* GetSurfaceFactoryOzone() override {
25 return window_manager_.get(); 26 return window_manager_.get();
26 } 27 }
27 CursorFactoryOzone* GetCursorFactoryOzone() override { 28 CursorFactoryOzone* GetCursorFactoryOzone() override {
28 return cursor_factory_ozone_.get(); 29 return cursor_factory_ozone_.get();
29 } 30 }
30 GpuPlatformSupport* GetGpuPlatformSupport() override { 31 GpuPlatformSupport* GetGpuPlatformSupport() override {
31 return NULL; // no GPU support 32 return NULL; // no GPU support
32 } 33 }
33 GpuPlatformSupportHost* GetGpuPlatformSupportHost() override { 34 GpuPlatformSupportHost* GetGpuPlatformSupportHost() override {
34 return NULL; // no GPU support 35 return NULL; // no GPU support
35 } 36 }
37 scoped_ptr<SystemInputInjector> CreateSystemInputInjector() override {
38 return nullptr; // no input injection support.
39 }
36 scoped_ptr<PlatformWindow> CreatePlatformWindow( 40 scoped_ptr<PlatformWindow> CreatePlatformWindow(
37 PlatformWindowDelegate* delegate, 41 PlatformWindowDelegate* delegate,
38 const gfx::Rect& bounds) override { 42 const gfx::Rect& bounds) override {
39 scoped_ptr<CacaWindow> caca_window(new CacaWindow( 43 scoped_ptr<CacaWindow> caca_window(new CacaWindow(
40 delegate, window_manager_.get(), event_source_.get(), bounds)); 44 delegate, window_manager_.get(), event_source_.get(), bounds));
41 if (!caca_window->Initialize()) 45 if (!caca_window->Initialize())
42 return nullptr; 46 return nullptr;
43 return caca_window.Pass(); 47 return caca_window.Pass();
44 } 48 }
45 scoped_ptr<NativeDisplayDelegate> CreateNativeDisplayDelegate() override { 49 scoped_ptr<NativeDisplayDelegate> CreateNativeDisplayDelegate() override {
(...skipping 14 matching lines...) Expand all
60 scoped_ptr<CursorFactoryOzone> cursor_factory_ozone_; 64 scoped_ptr<CursorFactoryOzone> cursor_factory_ozone_;
61 65
62 DISALLOW_COPY_AND_ASSIGN(OzonePlatformCaca); 66 DISALLOW_COPY_AND_ASSIGN(OzonePlatformCaca);
63 }; 67 };
64 68
65 } // namespace 69 } // namespace
66 70
67 OzonePlatform* CreateOzonePlatformCaca() { return new OzonePlatformCaca; } 71 OzonePlatform* CreateOzonePlatformCaca() { return new OzonePlatformCaca; }
68 72
69 } // namespace ui 73 } // namespace ui
OLDNEW
« no previous file with comments | « ui/ozone/ozone.gyp ('k') | ui/ozone/platform/dri/ozone_platform_dri.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698