| 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_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/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 76 // Shows the root window host. | 76 // Shows the root window host. |
| 77 void ShowRootWindow(); | 77 void ShowRootWindow(); |
| 78 | 78 |
| 79 // Sets the size of the root window. | 79 // Sets the size of the root window. |
| 80 void SetHostSize(const gfx::Size& size); | 80 void SetHostSize(const gfx::Size& size); |
| 81 gfx::Size GetHostSize() const; | 81 gfx::Size GetHostSize() const; |
| 82 | 82 |
| 83 // Sets the currently-displayed cursor. If the cursor was previously hidden | 83 // Sets the currently-displayed cursor. If the cursor was previously hidden |
| 84 // via ShowCursor(false), it will remain hidden until ShowCursor(true) is | 84 // via ShowCursor(false), it will remain hidden until ShowCursor(true) is |
| 85 // called, at which point the cursor that was last set via SetCursor() will be | 85 // called, at which point the cursor that was last set via SetCursor() will be |
| 86 // used. | 86 // used. To set a custom cursor, use SetCustomCursor instead. |
| 87 void SetCursor(gfx::NativeCursor cursor); | 87 void SetCursor(gfx::NativeCursor cursor); |
| 88 | 88 |
| 89 // Sets a custom cursor for the display. This interacts with ShowCursor the |
| 90 // same as SetCursor (see above). |
| 91 void SetCustomCursor(const gfx::PlatformCursor& cursor); |
| 92 |
| 89 // Shows or hides the cursor. | 93 // Shows or hides the cursor. |
| 90 void ShowCursor(bool show); | 94 void ShowCursor(bool show); |
| 91 | 95 |
| 92 // Moves the cursor to the specified location relative to the root window. | 96 // Moves the cursor to the specified location relative to the root window. |
| 93 void MoveCursorTo(const gfx::Point& location); | 97 void MoveCursorTo(const gfx::Point& location); |
| 94 | 98 |
| 95 // Clips the cursor movement to |capture_window_|. Should be invoked only | 99 // Clips the cursor movement to |capture_window_|. Should be invoked only |
| 96 // after SetCapture(). ReleaseCapture() implicitly removes any confines set | 100 // after SetCapture(). ReleaseCapture() implicitly removes any confines set |
| 97 // using this function. Returns true if successful. | 101 // using this function. Returns true if successful. |
| 98 bool ConfineCursorToWindow(); | 102 bool ConfineCursorToWindow(); |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 311 scoped_ptr<GestureRecognizer> gesture_recognizer_; | 315 scoped_ptr<GestureRecognizer> gesture_recognizer_; |
| 312 | 316 |
| 313 bool synthesize_mouse_move_; | 317 bool synthesize_mouse_move_; |
| 314 | 318 |
| 315 DISALLOW_COPY_AND_ASSIGN(RootWindow); | 319 DISALLOW_COPY_AND_ASSIGN(RootWindow); |
| 316 }; | 320 }; |
| 317 | 321 |
| 318 } // namespace aura | 322 } // namespace aura |
| 319 | 323 |
| 320 #endif // UI_AURA_ROOT_WINDOW_H_ | 324 #endif // UI_AURA_ROOT_WINDOW_H_ |
| OLD | NEW |