blob: cf0ec17b3d6536efdc2410aba08bf583f37ea5e5 [file] [log] [blame]
[email protected]e0d22e82012-01-04 00:46:571// Copyright (c) 2012 The Chromium Authors. All rights reserved.
[email protected]87b0d82e2011-10-07 21:02:592// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
[email protected]b65bdda2011-12-23 23:35:315#ifndef ASH_SHELL_H_
6#define ASH_SHELL_H_
[email protected]87b0d82e2011-10-07 21:02:597#pragma once
8
[email protected]cac10fc62011-10-07 23:22:569#include <utility>
10#include <vector>
11
[email protected]b65bdda2011-12-23 23:35:3112#include "ash/ash_export.h"
[email protected]82d3954ae2012-04-20 09:02:2213#include "ash/system/user/login_status.h"
[email protected]09f3fc82012-03-26 23:26:5614#include "ash/wm/shelf_auto_hide_behavior.h"
[email protected]87b0d82e2011-10-07 21:02:5915#include "base/basictypes.h"
[email protected]c45fdc72012-02-22 22:59:1216#include "base/compiler_specific.h"
[email protected]b0639282011-12-22 21:12:2717#include "base/gtest_prod_util.h"
[email protected]2b99f8c2011-10-11 19:42:2418#include "base/memory/scoped_ptr.h"
[email protected]1a2145b2012-03-13 21:09:1719#include "base/observer_list.h"
[email protected]1aad3322012-06-06 06:37:0920#include "ui/aura/cursor_delegate.h"
[email protected]2eb6b892012-05-31 13:28:2121#include "ui/gfx/insets.h"
[email protected]9ec0f452012-05-31 15:58:5322#include "ui/gfx/size.h"
[email protected]87b0d82e2011-10-07 21:02:5923
[email protected]b0639282011-12-22 21:12:2724class CommandLine;
25
[email protected]87b0d82e2011-10-07 21:02:5926namespace aura {
[email protected]e29014c2011-11-16 18:25:5127class EventFilter;
[email protected]a857dbe2012-05-30 22:10:1428class FocusManager;
[email protected]35304ce2011-12-14 23:21:0129class RootWindow;
[email protected]87b0d82e2011-10-07 21:02:5930class Window;
[email protected]c28853612012-05-31 22:43:4431namespace client {
32class UserActionClient;
33}
[email protected]0e46c272012-05-15 18:15:2334namespace shared {
[email protected]1aad3322012-06-06 06:37:0935class CompoundEventFilter;
[email protected]0e46c272012-05-15 18:15:2336class InputMethodEventFilter;
[email protected]0e46c272012-05-15 18:15:2337}
[email protected]87b0d82e2011-10-07 21:02:5938}
[email protected]70b3e7d52012-06-02 22:12:2539namespace chromeos {
40class OutputConfigurator;
41}
[email protected]fa4a45832012-04-12 21:32:4842namespace content {
43class BrowserContext;
44}
45
[email protected]2b99f8c2011-10-11 19:42:2446namespace gfx {
[email protected]9ec0f452012-05-31 15:58:5347class ImageSkia;
[email protected]b5f30602012-01-30 15:16:5748class Point;
[email protected]cac10fc62011-10-07 23:22:5649class Rect;
50}
[email protected]a8bd1cb2012-02-17 23:05:5451namespace ui {
52class Layer;
53}
[email protected]57b8bb352012-01-11 05:11:4654namespace views {
55class NonClientFrameView;
56class Widget;
57}
[email protected]87b0d82e2011-10-07 21:02:5958
[email protected]55f593352011-12-24 05:42:4659namespace ash {
[email protected]87b0d82e2011-10-07 21:02:5960
[email protected]2f744282011-12-23 22:40:5261class AcceleratorController;
[email protected]e70cf0ed2012-03-15 16:24:4762class DesktopBackgroundController;
[email protected]f48075d2012-05-24 11:06:5163class HighContrastController;
[email protected]671a2ae2011-10-13 21:53:2364class Launcher;
[email protected]8f80db0f2012-02-07 14:44:5365class NestedDispatcherController;
[email protected]e0d22e82012-01-04 00:46:5766class PowerButtonController;
[email protected]1a2145b2012-03-13 21:09:1767class ScreenAsh;
[email protected]2b99f8c2011-10-11 19:42:2468class ShellDelegate;
[email protected]1a2145b2012-03-13 21:09:1769class ShellObserver;
[email protected]bfb411312012-02-27 20:59:2770class SystemTrayDelegate;
71class SystemTray;
[email protected]c16b9422012-06-06 21:51:1172class UserActivityDetector;
[email protected]10b22612012-03-22 17:07:5573class UserWallpaperDelegate;
[email protected]6aa614a2012-01-19 22:13:3874class VideoDetector;
[email protected]40c4cbb2012-01-10 23:26:0775class WindowCycleController;
[email protected]60fa9bba2011-10-28 21:21:5176
77namespace internal {
[email protected]2f744282011-12-23 22:40:5278class AcceleratorFilter;
[email protected]0039db92012-05-09 04:11:4579class ActivationController;
80class AppListController;
[email protected]60a978b72012-06-08 00:29:1881class CaptureController;
[email protected]084b6bb2011-11-17 05:18:1682class DragDropController;
[email protected]3d29912a2012-02-07 07:41:5183class FocusCycler;
[email protected]42f06f92012-03-27 00:57:5784class KeyRewriterEventFilter;
[email protected]c1c670172012-04-26 04:20:2685class MagnificationController;
[email protected]e050ef142012-03-21 01:04:2486class MonitorController;
[email protected]7cf8dd62012-04-22 05:14:5887class PanelLayoutManager;
[email protected]0b0b0742012-02-16 13:23:4588class PartialScreenshotEventFilter;
[email protected]e4a181cc2012-03-17 02:20:5789class ResizeShadowController;
[email protected]d90b8392012-06-13 09:34:5690class RootWindowController;
[email protected]b0079a92012-01-25 20:13:3891class RootWindowLayoutManager;
[email protected]a54e65b2011-11-21 22:03:3492class ShadowController;
[email protected]4e437632012-02-13 22:39:4093class ShelfLayoutManager;
[email protected]0cfc18e2012-04-11 18:17:4794class ShellContextMenu;
[email protected]9861f1752012-06-01 07:16:1495class SlowAnimationEventFilter;
[email protected]435b212e2012-04-05 19:43:3796class SystemGestureEventFilter;
[email protected]ee1e1a22011-12-15 01:51:1097class StackingController;
[email protected]6d6546e2012-05-30 23:12:0298class StatusAreaWidget;
[email protected]862deef2011-12-15 22:07:3399class TooltipController;
[email protected]73074742012-05-17 01:44:41100class TouchObserverHUD;
[email protected]ddd91e92012-01-27 16:03:48101class VisibilityController;
[email protected]80373572012-01-06 23:14:30102class WindowModalityController;
[email protected]60fa9bba2011-10-28 21:21:51103class WorkspaceController;
104}
[email protected]2b99f8c2011-10-11 19:42:24105
[email protected]87b0d82e2011-10-07 21:02:59106// Shell is a singleton object that presents the Shell API and implements the
[email protected]99f07e02011-12-07 00:02:59107// RootWindow's delegate interface.
[email protected]b0079a92012-01-25 20:13:38108//
109// Upon creation, the Shell sets itself as the RootWindow's delegate, which
110// takes ownership of the Shell.
[email protected]1aad3322012-06-06 06:37:09111class ASH_EXPORT Shell : aura::CursorDelegate {
[email protected]87b0d82e2011-10-07 21:02:59112 public:
[email protected]be65be362012-06-15 07:38:23113 typedef std::vector<aura::RootWindow*> RootWindowList;
114 typedef std::vector<internal::RootWindowController*> RootWindowControllerList;
115
[email protected]3d29912a2012-02-07 07:41:51116 enum Direction {
117 FORWARD,
118 BACKWARD
119 };
120
[email protected]2b4cd302012-02-24 20:21:13121 // Accesses private data from a Shell for testing.
122 class ASH_EXPORT TestApi {
123 public:
124 explicit TestApi(Shell* shell);
125
[email protected]2b4cd302012-02-24 20:21:13126 internal::RootWindowLayoutManager* root_window_layout();
[email protected]0e46c272012-05-15 18:15:23127 aura::shared::InputMethodEventFilter* input_method_event_filter();
[email protected]435b212e2012-04-05 19:43:37128 internal::SystemGestureEventFilter* system_gesture_event_filter();
[email protected]db9131602012-02-29 19:06:32129 internal::WorkspaceController* workspace_controller();
[email protected]2b4cd302012-02-24 20:21:13130
131 private:
132 Shell* shell_; // not owned
133
134 DISALLOW_COPY_AND_ASSIGN(TestApi);
135 };
136
[email protected]3266c2b92011-11-14 00:06:08137 // A shell must be explicitly created so that it can call |Init()| with the
138 // delegate set. |delegate| can be NULL (if not required for initialization).
139 static Shell* CreateInstance(ShellDelegate* delegate);
140
141 // Should never be called before |CreateInstance()|.
[email protected]cac10fc62011-10-07 23:22:56142 static Shell* GetInstance();
[email protected]3266c2b92011-11-14 00:06:08143
[email protected]b3b7bcd2012-03-06 19:35:45144 // Returns true if the ash shell has been instantiated.
145 static bool HasInstance();
146
[email protected]ef589af2011-12-03 01:07:15147 static void DeleteInstance();
[email protected]cac10fc62011-10-07 23:22:56148
[email protected]d90b8392012-06-13 09:34:56149 // Returns the root window controller for the primary root window.
150 static internal::RootWindowController* GetPrimaryRootWindowController();
151
[email protected]be65be362012-06-15 07:38:23152 // Returns all root window controllers. In non extended desktop
153 // mode, this return a RootWindowController for the primary root window only.
154 static RootWindowControllerList GetAllRootWindowControllers();
155
156 // Returns the primary RootWindow. The primary RootWindow is the one
[email protected]42713f72012-05-25 00:41:50157 // that has a launcher.
158 static aura::RootWindow* GetPrimaryRootWindow();
[email protected]e73bd7802012-02-17 20:10:34159
[email protected]be65be362012-06-15 07:38:23160 // Returns the active RootWindow. The active RootWindow is the one that
[email protected]a857dbe2012-05-30 22:10:14161 // contains the current active window as a decendant child. The active
162 // RootWindow remains the same even when the active window becomes NULL,
163 // until the another window who has a different root window becomes active.
164 static aura::RootWindow* GetActiveRootWindow();
165
[email protected]be65be362012-06-15 07:38:23166 // Returns the RootWindow at |point| in the virtual screen coordinates.
[email protected]f18e84522012-06-05 00:34:18167 // Returns NULL if the root window does not exist at the given
168 // point.
169 static aura::RootWindow* GetRootWindowAt(const gfx::Point& point);
170
[email protected]be65be362012-06-15 07:38:23171 // Returns all root windows. In non extended desktop mode, this
172 // returns the primary root window only.
173 static RootWindowList GetAllRootWindows();
174
[email protected]7b0f7502012-06-11 00:12:39175 static aura::Window* GetContainer(aura::RootWindow* root_window,
176 int container_id);
177
178 // Returns the list of containers that match |container_id| in
179 // all root windows.
180 static std::vector<aura::Window*> GetAllContainers(int container_id);
181
[email protected]a857dbe2012-05-30 22:10:14182 void set_active_root_window(aura::RootWindow* active_root_window) {
183 active_root_window_ = active_root_window;
184 }
185
[email protected]1aad3322012-06-06 06:37:09186 // Adds or removes |filter| from the aura::Env's CompoundEventFilter.
187 void AddEnvEventFilter(aura::EventFilter* filter);
188 void RemoveEnvEventFilter(aura::EventFilter* filter);
189 size_t GetEnvEventFilterCount() const;
[email protected]e29014c2011-11-16 18:25:51190
[email protected]b5f30602012-01-30 15:16:57191 // Shows the background menu over |widget|.
192 void ShowBackgroundMenu(views::Widget* widget, const gfx::Point& location);
[email protected]cac10fc62011-10-07 23:22:56193
[email protected]ae4987d2011-11-21 22:52:44194 // Toggles app list.
195 void ToggleAppList();
196
[email protected]7510d1082012-03-30 21:58:34197 // Returns app list target visibility.
198 bool GetAppListTargetVisibility() const;
199
[email protected]1e51a9d2012-04-09 23:31:11200 // Returns app list window or NULL if it is not visible.
201 aura::Window* GetAppListWindow();
202
[email protected]f7eb89c2011-12-13 09:48:54203 // Returns true if the screen is locked.
204 bool IsScreenLocked() const;
205
[email protected]40c4cbb2012-01-10 23:26:07206 // Returns true if a modal dialog window is currently open.
207 bool IsModalWindowOpen() const;
208
[email protected]57b8bb352012-01-11 05:11:46209 // Creates a default views::NonClientFrameView for use by windows in the
210 // Ash environment.
211 views::NonClientFrameView* CreateDefaultNonClientFrameView(
212 views::Widget* widget);
213
[email protected]d9456cb2012-03-21 16:41:04214 // Rotates focus through containers that can receive focus.
[email protected]3d29912a2012-02-07 07:41:51215 void RotateFocus(Direction direction);
216
[email protected]8a45c972012-03-14 18:22:44217 // Sets the work area insets of the monitor that contains |window|,
218 // this notifies observers too.
[email protected]27f6af62012-03-21 05:34:40219 // TODO(sky): this no longer really replicates what happens and is unreliable.
220 // Remove this.
[email protected]8a45c972012-03-14 18:22:44221 void SetMonitorWorkAreaInsets(aura::Window* window,
222 const gfx::Insets& insets);
[email protected]1a2145b2012-03-13 21:09:17223
[email protected]82d3954ae2012-04-20 09:02:22224 // Called when the user logs in.
225 void OnLoginStateChanged(user::LoginStatus status);
226
227 // Called when the application is exiting.
228 void OnAppTerminating();
229
230 // Called when the screen is locked (after the lock window is visible) or
231 // unlocked.
232 void OnLockStateChanged(bool locked);
233
[email protected]d9456cb2012-03-21 16:41:04234 // Initializes |launcher_|. Does nothing if it's already initialized.
235 void CreateLauncher();
236
237 // Adds/removes observer.
[email protected]1a2145b2012-03-13 21:09:17238 void AddShellObserver(ShellObserver* observer);
239 void RemoveShellObserver(ShellObserver* observer);
240
[email protected]6e9f6aa2012-02-09 04:16:20241#if !defined(OS_MACOSX)
[email protected]2f744282011-12-23 22:40:52242 AcceleratorController* accelerator_controller() {
[email protected]745816be2011-11-22 05:08:30243 return accelerator_controller_.get();
244 }
[email protected]6e9f6aa2012-02-09 04:16:20245#endif // !defined(OS_MACOSX)
246
[email protected]1aad3322012-06-06 06:37:09247 aura::shared::CompoundEventFilter* env_filter() {
248 return env_filter_;
[email protected]627a62f2012-02-14 22:59:14249 }
[email protected]862deef2011-12-15 22:07:33250 internal::TooltipController* tooltip_controller() {
251 return tooltip_controller_.get();
[email protected]4a229e902011-12-01 21:21:11252 }
[email protected]42f06f92012-03-27 00:57:57253 internal::KeyRewriterEventFilter* key_rewriter_filter() {
254 return key_rewriter_filter_.get();
255 }
[email protected]0b0b0742012-02-16 13:23:45256 internal::PartialScreenshotEventFilter* partial_screenshot_filter() {
257 return partial_screenshot_filter_.get();
258 }
[email protected]e70cf0ed2012-03-15 16:24:47259 DesktopBackgroundController* desktop_background_controller() {
260 return desktop_background_controller_.get();
261 }
[email protected]e0d22e82012-01-04 00:46:57262 PowerButtonController* power_button_controller() {
263 return power_button_controller_.get();
264 }
[email protected]c16b9422012-06-06 21:51:11265 UserActivityDetector* user_activity_detector() {
266 return user_activity_detector_.get();
267 }
[email protected]6aa614a2012-01-19 22:13:38268 VideoDetector* video_detector() {
269 return video_detector_.get();
270 }
[email protected]40c4cbb2012-01-10 23:26:07271 WindowCycleController* window_cycle_controller() {
272 return window_cycle_controller_.get();
273 }
[email protected]2d511542012-03-07 09:13:34274 internal::FocusCycler* focus_cycler() {
275 return focus_cycler_.get();
276 }
[email protected]3e1cdd312012-06-07 03:48:41277 internal::MonitorController* monitor_controller() {
278 return monitor_controller_.get();
279 }
[email protected]4a229e902011-12-01 21:21:11280
[email protected]3266c2b92011-11-14 00:06:08281 ShellDelegate* delegate() { return delegate_.get(); }
[email protected]aa54218b2012-06-12 16:51:42282
[email protected]10b22612012-03-22 17:07:55283 UserWallpaperDelegate* user_wallpaper_delegate() {
284 return user_wallpaper_delegate_.get();
285 }
[email protected]35304ce2011-12-14 23:21:01286
[email protected]f48075d2012-05-24 11:06:51287 HighContrastController* high_contrast_controller() {
288 return high_contrast_controller_.get();
289 }
290
[email protected]c1c670172012-04-26 04:20:26291 internal::MagnificationController* magnification_controller() {
292 return magnification_controller_.get();
293 }
[email protected]f48075d2012-05-24 11:06:51294
[email protected]671a2ae2011-10-13 21:53:23295 Launcher* launcher() { return launcher_.get(); }
296
[email protected]1a2145b2012-03-13 21:09:17297 const ScreenAsh* screen() { return screen_; }
298
[email protected]c758fbf2012-03-25 22:53:59299 // Force the shelf to query for it's current visibility state.
300 void UpdateShelfVisibility();
301
[email protected]09f3fc82012-03-26 23:26:56302 // Sets/gets the shelf auto-hide behavior.
303 void SetShelfAutoHideBehavior(ShelfAutoHideBehavior behavior);
304 ShelfAutoHideBehavior GetShelfAutoHideBehavior() const;
[email protected]c758fbf2012-03-25 22:53:59305
[email protected]55444502012-05-10 15:43:53306 void SetShelfAlignment(ShelfAlignment alignment);
307 ShelfAlignment GetShelfAlignment();
308
[email protected]d90b8392012-06-13 09:34:56309 // Dims or undims the screen.
310 void SetDimming(bool should_dim);
311
[email protected]c758fbf2012-03-25 22:53:59312 // TODO(sky): don't expose this!
[email protected]4e437632012-02-13 22:39:40313 internal::ShelfLayoutManager* shelf() const { return shelf_; }
314
[email protected]6d6546e2012-05-30 23:12:02315 internal::StatusAreaWidget* status_area_widget() const {
316 return status_area_widget_;
317 }
318
[email protected]aa54218b2012-06-12 16:51:42319 // Convenience accessor for members of StatusAreaWidget.
320 SystemTrayDelegate* tray_delegate();
321 SystemTray* system_tray();
[email protected]bfb411312012-02-27 20:59:27322
[email protected]85d43f02012-03-14 21:11:19323 // Returns the size of the grid.
324 int GetGridSize() const;
325
[email protected]9488d4d2012-02-29 18:32:37326 static void set_initially_hide_cursor(bool hide) {
327 initially_hide_cursor_ = hide;
328 }
329
[email protected]e4a181cc2012-03-17 02:20:57330 internal::ResizeShadowController* resize_shadow_controller() {
331 return resize_shadow_controller_.get();
332 }
333
[email protected]a54e65b2011-11-21 22:03:34334 // Made available for tests.
335 internal::ShadowController* shadow_controller() {
336 return shadow_controller_.get();
337 }
338
[email protected]fa4a45832012-04-12 21:32:48339 content::BrowserContext* browser_context() { return browser_context_; }
340 void set_browser_context(content::BrowserContext* browser_context) {
341 browser_context_ = browser_context;
342 }
343
[email protected]be65be362012-06-15 07:38:23344 // Initializes the root window to be used for a secondary monitor.
[email protected]a857dbe2012-05-30 22:10:14345 void InitRootWindowForSecondaryMonitor(aura::RootWindow* root);
346
[email protected]70b3e7d52012-06-02 22:12:25347#if defined(OS_CHROMEOS)
348 chromeos::OutputConfigurator* output_configurator() {
349 return output_configurator_.get();
350 }
351#endif // defined(OS_CHROMEOS)
352
[email protected]2b4cd302012-02-24 20:21:13353 private:
[email protected]1aad3322012-06-06 06:37:09354 FRIEND_TEST_ALL_PREFIXES(WindowManagerTest, MouseEventCursors);
355 FRIEND_TEST_ALL_PREFIXES(WindowManagerTest, TransformActivate);
[email protected]d90b8392012-06-13 09:34:56356 friend class internal::RootWindowController;
[email protected]ad0c8722012-03-02 20:17:45357
[email protected]cac10fc62011-10-07 23:22:56358 typedef std::pair<aura::Window*, gfx::Rect> WindowAndBoundsPair;
359
[email protected]3266c2b92011-11-14 00:06:08360 explicit Shell(ShellDelegate* delegate);
361 virtual ~Shell();
362
363 void Init();
[email protected]b0639282011-12-22 21:12:27364
[email protected]be65be362012-06-15 07:38:23365 // Initializes the root window and root window controller so that it
366 // can host browser windows.
367 void InitRootWindowController(internal::RootWindowController* root);
[email protected]d90b8392012-06-13 09:34:56368
369 // Initializes the layout managers and event filters specific for
370 // primary display.
371 void InitLayoutManagersForPrimaryDisplay(
372 internal::RootWindowController* root_window_controller);
[email protected]1b62b892012-01-17 17:08:15373
[email protected]ad0c8722012-03-02 20:17:45374 // Disables the workspace grid layout.
375 void DisableWorkspaceGridLayout();
376
[email protected]1aad3322012-06-06 06:37:09377 // aura::CursorManager::Delegate overrides:
378 virtual void SetCursor(gfx::NativeCursor cursor) OVERRIDE;
379 virtual void ShowCursor(bool visible) OVERRIDE;
380
[email protected]cac10fc62011-10-07 23:22:56381 static Shell* instance_;
382
[email protected]9488d4d2012-02-29 18:32:37383 // If set before the Shell is initialized, the mouse cursor will be hidden
384 // when the screen is initially created.
385 static bool initially_hide_cursor_;
386
[email protected]1a2145b2012-03-13 21:09:17387 ScreenAsh* screen_;
[email protected]58482fa2012-03-02 14:57:39388
[email protected]a857dbe2012-05-30 22:10:14389 // Active root window. Never become NULL.
390 aura::RootWindow* active_root_window_;
391
[email protected]1aad3322012-06-06 06:37:09392 // The CompoundEventFilter owned by aura::Env object.
393 aura::shared::CompoundEventFilter* env_filter_;
[email protected]627a62f2012-02-14 22:59:14394
[email protected]cac10fc62011-10-07 23:22:56395 std::vector<WindowAndBoundsPair> to_restore_;
396
[email protected]6e9f6aa2012-02-09 04:16:20397#if !defined(OS_MACOSX)
[email protected]8f80db0f2012-02-07 14:44:53398 scoped_ptr<NestedDispatcherController> nested_dispatcher_controller_;
399
[email protected]2f744282011-12-23 22:40:52400 scoped_ptr<AcceleratorController> accelerator_controller_;
[email protected]6e9f6aa2012-02-09 04:16:20401#endif // !defined(OS_MACOSX)
[email protected]745816be2011-11-22 05:08:30402
[email protected]2b99f8c2011-10-11 19:42:24403 scoped_ptr<ShellDelegate> delegate_;
[email protected]10b22612012-03-22 17:07:55404 scoped_ptr<UserWallpaperDelegate> user_wallpaper_delegate_;
[email protected]2b99f8c2011-10-11 19:42:24405
[email protected]671a2ae2011-10-13 21:53:23406 scoped_ptr<Launcher> launcher_;
407
[email protected]0039db92012-05-09 04:11:45408 scoped_ptr<internal::AppListController> app_list_controller_;
[email protected]ae4987d2011-11-21 22:52:44409
[email protected]0cfc18e2012-04-11 18:17:47410 scoped_ptr<internal::ShellContextMenu> shell_context_menu_;
[email protected]ee1e1a22011-12-15 01:51:10411 scoped_ptr<internal::StackingController> stacking_controller_;
[email protected]9fc206d2011-12-13 00:05:33412 scoped_ptr<internal::ActivationController> activation_controller_;
[email protected]60a978b72012-06-08 00:29:18413 scoped_ptr<internal::CaptureController> capture_controller_;
[email protected]80373572012-01-06 23:14:30414 scoped_ptr<internal::WindowModalityController> window_modality_controller_;
[email protected]084b6bb2011-11-17 05:18:16415 scoped_ptr<internal::DragDropController> drag_drop_controller_;
[email protected]e4a181cc2012-03-17 02:20:57416 scoped_ptr<internal::ResizeShadowController> resize_shadow_controller_;
[email protected]a54e65b2011-11-21 22:03:34417 scoped_ptr<internal::ShadowController> shadow_controller_;
[email protected]862deef2011-12-15 22:07:33418 scoped_ptr<internal::TooltipController> tooltip_controller_;
[email protected]ddd91e92012-01-27 16:03:48419 scoped_ptr<internal::VisibilityController> visibility_controller_;
[email protected]e70cf0ed2012-03-15 16:24:47420 scoped_ptr<DesktopBackgroundController> desktop_background_controller_;
[email protected]e0d22e82012-01-04 00:46:57421 scoped_ptr<PowerButtonController> power_button_controller_;
[email protected]c16b9422012-06-06 21:51:11422 scoped_ptr<UserActivityDetector> user_activity_detector_;
[email protected]6aa614a2012-01-19 22:13:38423 scoped_ptr<VideoDetector> video_detector_;
[email protected]40c4cbb2012-01-10 23:26:07424 scoped_ptr<WindowCycleController> window_cycle_controller_;
[email protected]3d29912a2012-02-07 07:41:51425 scoped_ptr<internal::FocusCycler> focus_cycler_;
[email protected]e050ef142012-03-21 01:04:24426 scoped_ptr<internal::MonitorController> monitor_controller_;
[email protected]f48075d2012-05-24 11:06:51427 scoped_ptr<HighContrastController> high_contrast_controller_;
[email protected]c1c670172012-04-26 04:20:26428 scoped_ptr<internal::MagnificationController> magnification_controller_;
[email protected]a857dbe2012-05-30 22:10:14429 scoped_ptr<aura::FocusManager> focus_manager_;
[email protected]c28853612012-05-31 22:43:44430 scoped_ptr<aura::client::UserActionClient> user_action_client_;
[email protected]ae18b9112011-11-07 16:59:13431
[email protected]42f06f92012-03-27 00:57:57432 // An event filter that rewrites or drops a key event.
433 scoped_ptr<internal::KeyRewriterEventFilter> key_rewriter_filter_;
[email protected]6e9f6aa2012-02-09 04:16:20434
[email protected]0b0b0742012-02-16 13:23:45435 // An event filter that pre-handles key events while the partial
436 // screenshot UI is active.
437 scoped_ptr<internal::PartialScreenshotEventFilter> partial_screenshot_filter_;
438
[email protected]435b212e2012-04-05 19:43:37439 // An event filter which handles system level gestures
440 scoped_ptr<internal::SystemGestureEventFilter> system_gesture_filter_;
441
[email protected]6e9f6aa2012-02-09 04:16:20442#if !defined(OS_MACOSX)
[email protected]745816be2011-11-22 05:08:30443 // An event filter that pre-handles global accelerators.
[email protected]2f744282011-12-23 22:40:52444 scoped_ptr<internal::AcceleratorFilter> accelerator_filter_;
[email protected]6e9f6aa2012-02-09 04:16:20445#endif
[email protected]745816be2011-11-22 05:08:30446
[email protected]42f06f92012-03-27 00:57:57447 // An event filter that pre-handles all key events to send them to an IME.
[email protected]0e46c272012-05-15 18:15:23448 scoped_ptr<aura::shared::InputMethodEventFilter> input_method_filter_;
[email protected]42f06f92012-03-27 00:57:57449
[email protected]73074742012-05-17 01:44:41450 // An event filter that silently keeps track of all touch events and controls
451 // a heads-up display. This is enabled only if --ash-touch-hud flag is used.
452 scoped_ptr<internal::TouchObserverHUD> touch_observer_hud_;
453
[email protected]9861f1752012-06-01 07:16:14454 // An event filter that looks for modifier keypresses and triggers a slowdown
455 // of layer animations for visual debugging.
456 scoped_ptr<internal::SlowAnimationEventFilter> slow_animation_filter_;
457
[email protected]70b3e7d52012-06-02 22:12:25458#if defined(OS_CHROMEOS)
459 // Controls video output device state.
460 scoped_ptr<chromeos::OutputConfigurator> output_configurator_;
461#endif // defined(OS_CHROMEOS)
462
[email protected]4e437632012-02-13 22:39:40463 // The shelf for managing the launcher and the status widget in non-compact
464 // mode. Shell does not own the shelf. Instead, it is owned by container of
465 // the status area.
466 internal::ShelfLayoutManager* shelf_;
467
[email protected]7cf8dd62012-04-22 05:14:58468 // Manages layout of panels. Owned by PanelContainer.
469 internal::PanelLayoutManager* panel_layout_manager_;
470
[email protected]1a2145b2012-03-13 21:09:17471 ObserverList<ShellObserver> observers_;
472
[email protected]6d6546e2012-05-30 23:12:02473 // Widget containing system tray.
474 internal::StatusAreaWidget* status_area_widget_;
475
[email protected]fa4a45832012-04-12 21:32:48476 // Used by ash/shell.
477 content::BrowserContext* browser_context_;
478
[email protected]87b0d82e2011-10-07 21:02:59479 DISALLOW_COPY_AND_ASSIGN(Shell);
480};
481
[email protected]55f593352011-12-24 05:42:46482} // namespace ash
[email protected]87b0d82e2011-10-07 21:02:59483
[email protected]b65bdda2011-12-23 23:35:31484#endif // ASH_SHELL_H_