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

Side by Side Diff: ash/shell.h

Issue 11035050: Enable CursorManager::LockCursor to lock cursor visibility. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 ASH_SHELL_H_ 5 #ifndef ASH_SHELL_H_
6 #define ASH_SHELL_H_ 6 #define ASH_SHELL_H_
7 7
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
11 #include "ash/ash_export.h" 11 #include "ash/ash_export.h"
12 #include "ash/system/user/login_status.h" 12 #include "ash/system/user/login_status.h"
13 #include "ash/wm/cursor_delegate.h"
14 #include "ash/wm/cursor_manager.h" 13 #include "ash/wm/cursor_manager.h"
15 #include "ash/wm/shelf_types.h" 14 #include "ash/wm/shelf_types.h"
16 #include "base/basictypes.h" 15 #include "base/basictypes.h"
17 #include "base/compiler_specific.h" 16 #include "base/compiler_specific.h"
18 #include "base/gtest_prod_util.h" 17 #include "base/gtest_prod_util.h"
19 #include "base/memory/scoped_ptr.h" 18 #include "base/memory/scoped_ptr.h"
20 #include "base/observer_list.h" 19 #include "base/observer_list.h"
21 #include "ui/gfx/insets.h" 20 #include "ui/gfx/insets.h"
22 #include "ui/gfx/size.h" 21 #include "ui/gfx/size.h"
23 22
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 class VisibilityController; 104 class VisibilityController;
106 class WindowModalityController; 105 class WindowModalityController;
107 class WorkspaceController; 106 class WorkspaceController;
108 } 107 }
109 108
110 // Shell is a singleton object that presents the Shell API and implements the 109 // Shell is a singleton object that presents the Shell API and implements the
111 // RootWindow's delegate interface. 110 // RootWindow's delegate interface.
112 // 111 //
113 // Upon creation, the Shell sets itself as the RootWindow's delegate, which 112 // Upon creation, the Shell sets itself as the RootWindow's delegate, which
114 // takes ownership of the Shell. 113 // takes ownership of the Shell.
115 class ASH_EXPORT Shell : ash::CursorDelegate { 114 class ASH_EXPORT Shell {
116 public: 115 public:
117 typedef std::vector<aura::RootWindow*> RootWindowList; 116 typedef std::vector<aura::RootWindow*> RootWindowList;
118 typedef std::vector<internal::RootWindowController*> RootWindowControllerList; 117 typedef std::vector<internal::RootWindowController*> RootWindowControllerList;
119 118
120 enum Direction { 119 enum Direction {
121 FORWARD, 120 FORWARD,
122 BACKWARD 121 BACKWARD
123 }; 122 };
124 123
125 // Accesses private data from a Shell for testing. 124 // Accesses private data from a Shell for testing.
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 376
378 // Initializes the root window and root window controller so that it 377 // Initializes the root window and root window controller so that it
379 // can host browser windows. 378 // can host browser windows.
380 void InitRootWindowController(internal::RootWindowController* root); 379 void InitRootWindowController(internal::RootWindowController* root);
381 380
382 // Initializes the layout managers and event filters specific for 381 // Initializes the layout managers and event filters specific for
383 // primary display. 382 // primary display.
384 void InitLayoutManagersForPrimaryDisplay( 383 void InitLayoutManagersForPrimaryDisplay(
385 internal::RootWindowController* root_window_controller); 384 internal::RootWindowController* root_window_controller);
386 385
387 // aura::CursorManager::Delegate overrides:
388 virtual void SetCursor(gfx::NativeCursor cursor) OVERRIDE;
389 virtual void ShowCursor(bool visible) OVERRIDE;
390
391 static Shell* instance_; 386 static Shell* instance_;
392 387
393 // If set before the Shell is initialized, the mouse cursor will be hidden 388 // If set before the Shell is initialized, the mouse cursor will be hidden
394 // when the screen is initially created. 389 // when the screen is initially created.
395 static bool initially_hide_cursor_; 390 static bool initially_hide_cursor_;
396 391
397 ScreenAsh* screen_; 392 ScreenAsh* screen_;
398 393
399 // Active root window. Never becomes NULL during the session. 394 // Active root window. Never becomes NULL during the session.
400 aura::RootWindow* active_root_window_; 395 aura::RootWindow* active_root_window_;
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 483
489 // Used by ash/shell. 484 // Used by ash/shell.
490 content::BrowserContext* browser_context_; 485 content::BrowserContext* browser_context_;
491 486
492 DISALLOW_COPY_AND_ASSIGN(Shell); 487 DISALLOW_COPY_AND_ASSIGN(Shell);
493 }; 488 };
494 489
495 } // namespace ash 490 } // namespace ash
496 491
497 #endif // ASH_SHELL_H_ 492 #endif // ASH_SHELL_H_
OLDNEW
« no previous file with comments | « ash/magnifier/magnification_controller.cc ('k') | ash/shell.cc » ('j') | ash/wm/cursor_manager.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698