| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_ROOT_WINDOW_H_ | 5 #ifndef UI_AURA_ROOT_WINDOW_H_ |
| 6 #define UI_AURA_ROOT_WINDOW_H_ | 6 #define UI_AURA_ROOT_WINDOW_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| 11 #include "base/memory/weak_ptr.h" | 11 #include "base/memory/weak_ptr.h" |
| 12 #include "base/message_loop.h" | 12 #include "base/message_loop.h" |
| 13 #include "base/task.h" | 13 #include "base/task.h" |
| 14 #include "ui/aura/aura_export.h" | 14 #include "ui/aura/aura_export.h" |
| 15 #include "ui/aura/cursor.h" | 15 #include "ui/aura/cursor.h" |
| 16 #include "ui/aura/focus_manager.h" | 16 #include "ui/aura/focus_manager.h" |
| 17 #include "ui/aura/window.h" | 17 #include "ui/aura/window.h" |
| 18 #include "ui/base/events.h" | 18 #include "ui/base/events.h" |
| 19 #include "ui/gfx/compositor/compositor.h" | 19 #include "ui/gfx/compositor/compositor.h" |
| 20 #include "ui/gfx/compositor/layer_animation_observer.h" | 20 #include "ui/gfx/compositor/layer_animation_observer.h" |
| 21 #include "ui/gfx/native_widget_types.h" | 21 #include "ui/gfx/native_widget_types.h" |
| 22 #include "ui/gfx/point.h" | 22 #include "ui/gfx/point.h" |
| 23 | 23 |
| 24 namespace gfx { | 24 namespace gfx { |
| 25 class Size; | 25 class Size; |
| 26 } | 26 } |
| 27 | 27 |
| 28 namespace ui { | 28 namespace ui { |
| 29 class InputMethod; |
| 29 class LayerAnimationSequence; | 30 class LayerAnimationSequence; |
| 30 class Transform; | 31 class Transform; |
| 31 } | 32 } |
| 32 | 33 |
| 33 namespace aura { | 34 namespace aura { |
| 34 | 35 |
| 35 class RootWindowHost; | 36 class RootWindowHost; |
| 36 class RootWindowObserver; | 37 class RootWindowObserver; |
| 37 class KeyEvent; | 38 class KeyEvent; |
| 38 class MouseEvent; | 39 class MouseEvent; |
| (...skipping 15 matching lines...) Expand all Loading... |
| 54 } | 55 } |
| 55 | 56 |
| 56 ui::Compositor* compositor() { return compositor_.get(); } | 57 ui::Compositor* compositor() { return compositor_.get(); } |
| 57 gfx::Point last_mouse_location() const { return last_mouse_location_; } | 58 gfx::Point last_mouse_location() const { return last_mouse_location_; } |
| 58 gfx::NativeCursor last_cursor() const { return last_cursor_; } | 59 gfx::NativeCursor last_cursor() const { return last_cursor_; } |
| 59 StackingClient* stacking_client() { return stacking_client_.get(); } | 60 StackingClient* stacking_client() { return stacking_client_.get(); } |
| 60 Window* active_window() { return active_window_; } | 61 Window* active_window() { return active_window_; } |
| 61 Window* mouse_pressed_handler() { return mouse_pressed_handler_; } | 62 Window* mouse_pressed_handler() { return mouse_pressed_handler_; } |
| 62 Window* capture_window() { return capture_window_; } | 63 Window* capture_window() { return capture_window_; } |
| 63 ScreenAura* screen() { return screen_; } | 64 ScreenAura* screen() { return screen_; } |
| 65 void set_input_method(ui::InputMethod* input_method) { |
| 66 input_method_ = input_method; // does not own |input_method|. |
| 67 } |
| 68 ui::InputMethod* input_method() const { return input_method_; } |
| 64 | 69 |
| 65 void SetStackingClient(StackingClient* stacking_client); | 70 void SetStackingClient(StackingClient* stacking_client); |
| 66 | 71 |
| 67 // Shows the root window host. | 72 // Shows the root window host. |
| 68 void ShowRootWindow(); | 73 void ShowRootWindow(); |
| 69 | 74 |
| 70 // Sets the size of the root window. | 75 // Sets the size of the root window. |
| 71 void SetHostSize(const gfx::Size& size); | 76 void SetHostSize(const gfx::Size& size); |
| 72 gfx::Size GetHostSize() const; | 77 gfx::Size GetHostSize() const; |
| 73 | 78 |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 229 | 234 |
| 230 // The capture window. When not-null, this window receives all the mouse and | 235 // The capture window. When not-null, this window receives all the mouse and |
| 231 // touch events. | 236 // touch events. |
| 232 Window* capture_window_; | 237 Window* capture_window_; |
| 233 | 238 |
| 234 Window* mouse_pressed_handler_; | 239 Window* mouse_pressed_handler_; |
| 235 Window* mouse_moved_handler_; | 240 Window* mouse_moved_handler_; |
| 236 Window* focused_window_; | 241 Window* focused_window_; |
| 237 Window* touch_event_handler_; | 242 Window* touch_event_handler_; |
| 238 | 243 |
| 244 ui::InputMethod* input_method_; |
| 245 |
| 239 DISALLOW_COPY_AND_ASSIGN(RootWindow); | 246 DISALLOW_COPY_AND_ASSIGN(RootWindow); |
| 240 }; | 247 }; |
| 241 | 248 |
| 242 } // namespace aura | 249 } // namespace aura |
| 243 | 250 |
| 244 #endif // UI_AURA_ROOT_WINDOW_H_ | 251 #endif // UI_AURA_ROOT_WINDOW_H_ |
| OLD | NEW |