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

Side by Side Diff: ash/root_window_controller.h

Issue 240333007: wip: Second crack at implementing the touch exploration mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Don't extend DisplayController::Observer - TouchExplorationController is owned by the root window (… Created 6 years, 8 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
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_ROOT_WINDOW_CONTROLLER_H_ 5 #ifndef ASH_ROOT_WINDOW_CONTROLLER_H_
6 #define ASH_ROOT_WINDOW_CONTROLLER_H_ 6 #define ASH_ROOT_WINDOW_CONTROLLER_H_
7 7
8 #include <map> 8 #include <map>
9 9
10 #include "ash/accessibility_delegate.h"
Daniel Erat 2014/04/18 00:44:08 do you need this include?
10 #include "ash/ash_export.h" 11 #include "ash/ash_export.h"
11 #include "ash/shelf/shelf_types.h" 12 #include "ash/shelf/shelf_types.h"
12 #include "ash/shell_observer.h" 13 #include "ash/shell_observer.h"
14 #include "ash/system/tray_accessibility.h"
13 #include "ash/system/user/login_status.h" 15 #include "ash/system/user/login_status.h"
16 #include "ash/touch/touch_exploration_controller.h"
Daniel Erat 2014/04/18 00:44:08 forward-declare TouchExplorationController and mov
14 #include "base/basictypes.h" 17 #include "base/basictypes.h"
15 #include "base/memory/scoped_ptr.h" 18 #include "base/memory/scoped_ptr.h"
16 #include "ui/aura/window.h" 19 #include "ui/aura/window.h"
17 #include "ui/aura/window_tree_host.h" 20 #include "ui/aura/window_tree_host.h"
18 #include "ui/base/ui_base_types.h" 21 #include "ui/base/ui_base_types.h"
19 22
20 class SkBitmap; 23 class SkBitmap;
21 24
22 namespace aura { 25 namespace aura {
23 class EventFilter; 26 class EventFilter;
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 class BootSplashScreen; 73 class BootSplashScreen;
71 #endif 74 #endif
72 75
73 // This class maintains the per root window state for ash. This class 76 // This class maintains the per root window state for ash. This class
74 // owns the root window and other dependent objects that should be 77 // owns the root window and other dependent objects that should be
75 // deleted upon the deletion of the root window. This object is 78 // deleted upon the deletion of the root window. This object is
76 // indirectly owned and deleted by |DisplayController|. 79 // indirectly owned and deleted by |DisplayController|.
77 // The RootWindowController for particular root window is stored in 80 // The RootWindowController for particular root window is stored in
78 // its property (RootWindowSettings) and can be obtained using 81 // its property (RootWindowSettings) and can be obtained using
79 // |GetRootWindowController(aura::WindowEventDispatcher*)| function. 82 // |GetRootWindowController(aura::WindowEventDispatcher*)| function.
80 class ASH_EXPORT RootWindowController : public ShellObserver { 83 class ASH_EXPORT RootWindowController : public ShellObserver,
84 public AccessibilityObserver {
81 public: 85 public:
82 86
83 // Creates and Initialize the RootWindowController for primary display. 87 // Creates and Initialize the RootWindowController for primary display.
84 static void CreateForPrimaryDisplay(AshWindowTreeHost* host); 88 static void CreateForPrimaryDisplay(AshWindowTreeHost* host);
85 89
86 // Creates and Initialize the RootWindowController for secondary displays. 90 // Creates and Initialize the RootWindowController for secondary displays.
87 static void CreateForSecondaryDisplay(AshWindowTreeHost* host); 91 static void CreateForSecondaryDisplay(AshWindowTreeHost* host);
88 92
89 // Creates and Initialize the RootWindowController for virtual 93 // Creates and Initialize the RootWindowController for virtual
90 // keyboard displays. 94 // keyboard displays.
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 // Enables projection touch HUD. 268 // Enables projection touch HUD.
265 void EnableTouchHudProjection(); 269 void EnableTouchHudProjection();
266 270
267 // Disables projection touch HUD. 271 // Disables projection touch HUD.
268 void DisableTouchHudProjection(); 272 void DisableTouchHudProjection();
269 273
270 // Overridden from ShellObserver. 274 // Overridden from ShellObserver.
271 virtual void OnLoginStateChanged(user::LoginStatus status) OVERRIDE; 275 virtual void OnLoginStateChanged(user::LoginStatus status) OVERRIDE;
272 virtual void OnTouchHudProjectionToggled(bool enabled) OVERRIDE; 276 virtual void OnTouchHudProjectionToggled(bool enabled) OVERRIDE;
273 277
278 void UpdateTouchExplorationState();
Daniel Erat 2014/04/18 00:44:08 nit: add a comment and move this above the ShellOb
279
280 // Overridden from AccessibilityObserver.
281 virtual void OnAccessibilityModeChanged(
282 AccessibilityNotificationVisibility notify) OVERRIDE;
283
274 scoped_ptr<AshWindowTreeHost> ash_host_; 284 scoped_ptr<AshWindowTreeHost> ash_host_;
275 RootWindowLayoutManager* root_window_layout_; 285 RootWindowLayoutManager* root_window_layout_;
276 286
277 scoped_ptr<StackingController> stacking_controller_; 287 scoped_ptr<StackingController> stacking_controller_;
278 288
279 // The shelf for managing the shelf and the status widget. 289 // The shelf for managing the shelf and the status widget.
280 scoped_ptr<ShelfWidget> shelf_; 290 scoped_ptr<ShelfWidget> shelf_;
281 291
282 // An invisible/empty window used as a event target for 292 // An invisible/empty window used as a event target for
283 // |MouseCursorEventFilter| before a user logs in. 293 // |MouseCursorEventFilter| before a user logs in.
(...skipping 22 matching lines...) Expand all
306 TouchHudDebug* touch_hud_debug_; 316 TouchHudDebug* touch_hud_debug_;
307 TouchHudProjection* touch_hud_projection_; 317 TouchHudProjection* touch_hud_projection_;
308 318
309 // Handles double clicks on the panel window header. 319 // Handles double clicks on the panel window header.
310 scoped_ptr<ui::EventHandler> panel_container_handler_; 320 scoped_ptr<ui::EventHandler> panel_container_handler_;
311 321
312 scoped_ptr<DesktopBackgroundWidgetController> wallpaper_controller_; 322 scoped_ptr<DesktopBackgroundWidgetController> wallpaper_controller_;
313 scoped_ptr<AnimatingDesktopController> animating_wallpaper_controller_; 323 scoped_ptr<AnimatingDesktopController> animating_wallpaper_controller_;
314 scoped_ptr< ::wm::ScopedCaptureClient> capture_client_; 324 scoped_ptr< ::wm::ScopedCaptureClient> capture_client_;
315 325
326 scoped_ptr<TouchExplorationController> touch_exploration_controller_;
327
316 DISALLOW_COPY_AND_ASSIGN(RootWindowController); 328 DISALLOW_COPY_AND_ASSIGN(RootWindowController);
317 }; 329 };
318 330
319 331
320 // Gets the RootWindowController for |root_window|. 332 // Gets the RootWindowController for |root_window|.
321 ASH_EXPORT RootWindowController* GetRootWindowController( 333 ASH_EXPORT RootWindowController* GetRootWindowController(
322 const aura::Window* root_window); 334 const aura::Window* root_window);
323 335
324 } // ash 336 } // ash
325 337
326 #endif // ASH_ROOT_WINDOW_CONTROLLER_H_ 338 #endif // ASH_ROOT_WINDOW_CONTROLLER_H_
OLDNEW
« no previous file with comments | « ash/ash.gyp ('k') | ash/root_window_controller.cc » ('j') | ash/root_window_controller.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698