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

Side by Side Diff: ui/aura/root_window.h

Issue 9689027: MonitorManager to manage multiple monitors. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: crash fix Created 8 years, 9 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 | Annotate | Revision Log
OLDNEW
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 19 matching lines...) Expand all
30 class LayerAnimationSequence; 30 class LayerAnimationSequence;
31 class Transform; 31 class Transform;
32 } 32 }
33 33
34 namespace aura { 34 namespace aura {
35 35
36 class RootWindowHost; 36 class RootWindowHost;
37 class RootWindowObserver; 37 class RootWindowObserver;
38 class KeyEvent; 38 class KeyEvent;
39 class MouseEvent; 39 class MouseEvent;
40 class ScreenAura;
41 class StackingClient; 40 class StackingClient;
42 class ScrollEvent; 41 class ScrollEvent;
43 class TouchEvent; 42 class TouchEvent;
44 class GestureEvent; 43 class GestureEvent;
45 44
46 // RootWindow is responsible for hosting a set of windows. 45 // RootWindow is responsible for hosting a set of windows.
47 class AURA_EXPORT RootWindow : public ui::CompositorDelegate, 46 class AURA_EXPORT RootWindow : public ui::CompositorDelegate,
48 public ui::CompositorObserver, 47 public ui::CompositorObserver,
49 public Window, 48 public Window,
50 public internal::FocusManager, 49 public internal::FocusManager,
(...skipping 15 matching lines...) Expand all
66 static bool hide_host_cursor() { 65 static bool hide_host_cursor() {
67 return hide_host_cursor_; 66 return hide_host_cursor_;
68 } 67 }
69 68
70 ui::Compositor* compositor() { return compositor_.get(); } 69 ui::Compositor* compositor() { return compositor_.get(); }
71 gfx::Point last_mouse_location() const { return last_mouse_location_; } 70 gfx::Point last_mouse_location() const { return last_mouse_location_; }
72 gfx::NativeCursor last_cursor() const { return last_cursor_; } 71 gfx::NativeCursor last_cursor() const { return last_cursor_; }
73 bool cursor_shown() const { return cursor_shown_; } 72 bool cursor_shown() const { return cursor_shown_; }
74 Window* mouse_pressed_handler() { return mouse_pressed_handler_; } 73 Window* mouse_pressed_handler() { return mouse_pressed_handler_; }
75 Window* capture_window() { return capture_window_; } 74 Window* capture_window() { return capture_window_; }
76 const ScreenAura* screen() { return screen_; }
77 75
78 // Shows the root window host. 76 // Shows the root window host.
79 void ShowRootWindow(); 77 void ShowRootWindow();
80 78
81 // Sets the size of the root window. 79 // Sets the size of the root window.
82 void SetHostSize(const gfx::Size& size); 80 void SetHostSize(const gfx::Size& size);
83 gfx::Size GetHostSize() const; 81 gfx::Size GetHostSize() const;
84 82
85 // Sets the screen's work area insets, this notifies observers too. 83 // Sets the monitor's work area insets, this notifies observers too.
86 void SetScreenWorkAreaInsets(const gfx::Insets& insets); 84 void SetMonitorWorkAreaInsets(const gfx::Insets& insets);
87 85
88 // Sets the currently-displayed cursor. If the cursor was previously hidden 86 // Sets the currently-displayed cursor. If the cursor was previously hidden
89 // via ShowCursor(false), it will remain hidden until ShowCursor(true) is 87 // via ShowCursor(false), it will remain hidden until ShowCursor(true) is
90 // called, at which point the cursor that was last set via SetCursor() will be 88 // called, at which point the cursor that was last set via SetCursor() will be
91 // used. 89 // used.
92 void SetCursor(gfx::NativeCursor cursor); 90 void SetCursor(gfx::NativeCursor cursor);
93 91
94 // Shows or hides the cursor. 92 // Shows or hides the cursor.
95 void ShowCursor(bool show); 93 void ShowCursor(bool show);
96 94
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after
288 int mouse_button_flags_; 286 int mouse_button_flags_;
289 287
290 // Last cursor set. Used for testing. 288 // Last cursor set. Used for testing.
291 gfx::NativeCursor last_cursor_; 289 gfx::NativeCursor last_cursor_;
292 290
293 // Is the cursor currently shown? Used for testing. 291 // Is the cursor currently shown? Used for testing.
294 bool cursor_shown_; 292 bool cursor_shown_;
295 293
296 ObserverList<RootWindowObserver> observers_; 294 ObserverList<RootWindowObserver> observers_;
297 295
298 ScreenAura* screen_;
299
300 // The capture window. When not-null, this window receives all the mouse and 296 // The capture window. When not-null, this window receives all the mouse and
301 // touch events. 297 // touch events.
302 Window* capture_window_; 298 Window* capture_window_;
303 299
304 Window* mouse_pressed_handler_; 300 Window* mouse_pressed_handler_;
305 Window* mouse_moved_handler_; 301 Window* mouse_moved_handler_;
306 Window* focused_window_; 302 Window* focused_window_;
307 Window* touch_event_handler_; 303 Window* touch_event_handler_;
308 Window* gesture_handler_; 304 Window* gesture_handler_;
309 305
310 // The gesture_recognizer_ for this. 306 // The gesture_recognizer_ for this.
311 scoped_ptr<GestureRecognizer> gesture_recognizer_; 307 scoped_ptr<GestureRecognizer> gesture_recognizer_;
312 308
313 bool synthesize_mouse_move_; 309 bool synthesize_mouse_move_;
314 bool waiting_on_compositing_end_; 310 bool waiting_on_compositing_end_;
315 bool draw_on_compositing_end_; 311 bool draw_on_compositing_end_;
316 312
317 DISALLOW_COPY_AND_ASSIGN(RootWindow); 313 DISALLOW_COPY_AND_ASSIGN(RootWindow);
318 }; 314 };
319 315
320 } // namespace aura 316 } // namespace aura
321 317
322 #endif // UI_AURA_ROOT_WINDOW_H_ 318 #endif // UI_AURA_ROOT_WINDOW_H_
OLDNEW
« ui/aura/monitor.h ('K') | « ui/aura/monitor_manager.cc ('k') | ui/aura/root_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698