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

Side by Side Diff: ui/events/ozone/evdev/cursor_delegate_evdev.h

Issue 2088533002: Refactor ozone drm cursor code for mojo (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix build Created 4 years, 6 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 | ui/events/ozone/evdev/event_converter_evdev_impl_unittest.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 #ifndef UI_EVENTS_OZONE_EVDEV_CURSOR_DELEGATE_EVDEV_H_ 5 #ifndef UI_EVENTS_OZONE_EVDEV_CURSOR_DELEGATE_EVDEV_H_
6 #define UI_EVENTS_OZONE_EVDEV_CURSOR_DELEGATE_EVDEV_H_ 6 #define UI_EVENTS_OZONE_EVDEV_CURSOR_DELEGATE_EVDEV_H_
7 7
8 #include "ui/events/ozone/evdev/events_ozone_evdev_export.h" 8 #include "ui/events/ozone/evdev/events_ozone_evdev_export.h"
9 #include "ui/gfx/geometry/point_f.h" 9 #include "ui/gfx/geometry/point_f.h"
10 #include "ui/gfx/native_widget_types.h" 10 #include "ui/gfx/native_widget_types.h"
11 11
12 namespace gfx { 12 namespace gfx {
13 class Vector2dF; 13 class Vector2dF;
14 class Rect; 14 class Rect;
15 } 15 }
16 16
17 namespace ui { 17 namespace ui {
18 18
19 class EVENTS_OZONE_EVDEV_EXPORT CursorDelegateEvdev { 19 class EVENTS_OZONE_EVDEV_EXPORT CursorDelegateEvdev {
20 public: 20 public:
21 virtual ~CursorDelegateEvdev() {} 21 virtual ~CursorDelegateEvdev() {}
22 22
23 // Move the cursor. 23 // Move the cursor from the Evdev thread.
24 virtual void MoveCursor(const gfx::Vector2dF& delta) = 0; 24 virtual void MoveCursor(const gfx::Vector2dF& delta) = 0;
25 // Move the cursor from the UI thread only.
25 virtual void MoveCursorTo(gfx::AcceleratedWidget widget, 26 virtual void MoveCursorTo(gfx::AcceleratedWidget widget,
26 const gfx::PointF& location) = 0; 27 const gfx::PointF& location) = 0;
28 // Move the cursor from the UI thread only.
27 virtual void MoveCursorTo(const gfx::PointF& location) = 0; 29 virtual void MoveCursorTo(const gfx::PointF& location) = 0;
28 30
29 // Location in screen. 31 // Location in screen. Either thread, IPC-free.
30 virtual gfx::PointF GetLocation() = 0; 32 virtual gfx::PointF GetLocation() = 0;
31 33
32 // Cursor visibility. 34 // Cursor visibility. Either thread, IPC-free.
33 virtual bool IsCursorVisible() = 0; 35 virtual bool IsCursorVisible() = 0;
34 36
35 // The bounds that the cursor is confined to. 37 // The bounds that the cursor is confined to. Either thread, IPC-free.
36 virtual gfx::Rect GetCursorConfinedBounds() = 0; 38 virtual gfx::Rect GetCursorConfinedBounds() = 0;
39
40 // Any necessary initialization from Evdev thread.
41 virtual void InitializeOnEvdev() = 0;
37 }; 42 };
38 43
39 } // namespace ui 44 } // namespace ui
40 45
41 #endif // UI_EVENTS_OZONE_EVDEV_CURSOR_DELEGATE_EVDEV_H_ 46 #endif // UI_EVENTS_OZONE_EVDEV_CURSOR_DELEGATE_EVDEV_H_
OLDNEW
« no previous file with comments | « no previous file | ui/events/ozone/evdev/event_converter_evdev_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698