OLD | NEW |
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_OZONE_PUBLIC_CURSOR_FACTORY_OZONE_H_ | 5 #ifndef UI_OZONE_PUBLIC_CURSOR_FACTORY_OZONE_H_ |
6 #define UI_OZONE_PUBLIC_CURSOR_FACTORY_OZONE_H_ | 6 #define UI_OZONE_PUBLIC_CURSOR_FACTORY_OZONE_H_ |
7 | 7 |
8 #include "ui/gfx/native_widget_types.h" | 8 #include "ui/gfx/native_widget_types.h" |
9 #include "ui/ozone/ozone_base_export.h" | 9 #include "ui/ozone/ozone_base_export.h" |
10 | 10 |
(...skipping 23 matching lines...) Expand all Loading... |
34 // CreateImageCursor call must be matched with a call to UnrefImageCursor. | 34 // CreateImageCursor call must be matched with a call to UnrefImageCursor. |
35 virtual PlatformCursor CreateImageCursor(const SkBitmap& bitmap, | 35 virtual PlatformCursor CreateImageCursor(const SkBitmap& bitmap, |
36 const gfx::Point& hotspot); | 36 const gfx::Point& hotspot); |
37 | 37 |
38 // Increment platform image cursor refcount. | 38 // Increment platform image cursor refcount. |
39 virtual void RefImageCursor(PlatformCursor cursor); | 39 virtual void RefImageCursor(PlatformCursor cursor); |
40 | 40 |
41 // Decrement platform image cursor refcount. | 41 // Decrement platform image cursor refcount. |
42 virtual void UnrefImageCursor(PlatformCursor cursor); | 42 virtual void UnrefImageCursor(PlatformCursor cursor); |
43 | 43 |
44 // Change the active cursor for an AcceleratedWidget. | |
45 // TODO(spang): Move this. | |
46 virtual void SetCursor(gfx::AcceleratedWidget widget, PlatformCursor cursor); | |
47 | |
48 // Returns the window on which the cursor is active. | |
49 // TODO(dnicoara) Move this once the WindowTreeHost refactoring finishes and | |
50 // WindowTreeHost::CanDispatchEvent() is no longer present. | |
51 virtual gfx::AcceleratedWidget GetCursorWindow(); | |
52 | |
53 private: | 44 private: |
54 static CursorFactoryOzone* impl_; // not owned | 45 static CursorFactoryOzone* impl_; // not owned |
55 }; | 46 }; |
56 | 47 |
57 } // namespace ui | 48 } // namespace ui |
58 | 49 |
59 #endif // UI_OZONE_PUBLIC_CURSOR_FACTORY_OZONE_H_ | 50 #endif // UI_OZONE_PUBLIC_CURSOR_FACTORY_OZONE_H_ |
OLD | NEW |