OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_AURA_WINDOW_TREE_HOST_H_ | 5 #ifndef UI_AURA_WINDOW_TREE_HOST_H_ |
6 #define UI_AURA_WINDOW_TREE_HOST_H_ | 6 #define UI_AURA_WINDOW_TREE_HOST_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/event_types.h" | 10 #include "base/event_types.h" |
11 #include "base/message_loop/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
12 #include "ui/aura/aura_export.h" | 12 #include "ui/aura/aura_export.h" |
13 #include "ui/base/cursor/cursor.h" | 13 #include "ui/base/cursor/cursor.h" |
| 14 #include "ui/events/event_source.h" |
14 #include "ui/gfx/native_widget_types.h" | 15 #include "ui/gfx/native_widget_types.h" |
15 | 16 |
16 namespace gfx { | 17 namespace gfx { |
17 class Insets; | 18 class Insets; |
18 class Point; | 19 class Point; |
19 class Rect; | 20 class Rect; |
20 class Size; | 21 class Size; |
21 class Transform; | 22 class Transform; |
22 } | 23 } |
23 | 24 |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
104 void OnCursorVisibilityChanged(bool visible); | 105 void OnCursorVisibilityChanged(bool visible); |
105 | 106 |
106 // Moves the cursor to the specified location relative to the root window. | 107 // Moves the cursor to the specified location relative to the root window. |
107 void MoveCursorTo(const gfx::Point& location); | 108 void MoveCursorTo(const gfx::Point& location); |
108 | 109 |
109 // Moves the cursor to the |host_location| given in host coordinates. | 110 // Moves the cursor to the |host_location| given in host coordinates. |
110 void MoveCursorToHostLocation(const gfx::Point& host_location); | 111 void MoveCursorToHostLocation(const gfx::Point& host_location); |
111 | 112 |
112 gfx::NativeCursor last_cursor() const { return last_cursor_; } | 113 gfx::NativeCursor last_cursor() const { return last_cursor_; } |
113 | 114 |
| 115 // Returns the EventSource responsible for dispatching events to the window |
| 116 // tree. |
| 117 virtual ui::EventSource* GetEventSource() = 0; |
| 118 |
114 // Returns the accelerated widget. | 119 // Returns the accelerated widget. |
115 virtual gfx::AcceleratedWidget GetAcceleratedWidget() = 0; | 120 virtual gfx::AcceleratedWidget GetAcceleratedWidget() = 0; |
116 | 121 |
117 // Shows the WindowTreeHost. | 122 // Shows the WindowTreeHost. |
118 virtual void Show() = 0; | 123 virtual void Show() = 0; |
119 | 124 |
120 // Hides the WindowTreeHost. | 125 // Hides the WindowTreeHost. |
121 virtual void Hide() = 0; | 126 virtual void Hide() = 0; |
122 | 127 |
123 // Gets/Sets the size of the WindowTreeHost. | 128 // Gets/Sets the size of the WindowTreeHost. |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
193 gfx::NativeCursor last_cursor_; | 198 gfx::NativeCursor last_cursor_; |
194 | 199 |
195 scoped_ptr<ui::ViewProp> prop_; | 200 scoped_ptr<ui::ViewProp> prop_; |
196 | 201 |
197 DISALLOW_COPY_AND_ASSIGN(WindowTreeHost); | 202 DISALLOW_COPY_AND_ASSIGN(WindowTreeHost); |
198 }; | 203 }; |
199 | 204 |
200 } // namespace aura | 205 } // namespace aura |
201 | 206 |
202 #endif // UI_AURA_WINDOW_TREE_HOST_H_ | 207 #endif // UI_AURA_WINDOW_TREE_HOST_H_ |
OLD | NEW |