Chromium Code Reviews| 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 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 "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
| 9 #include "ash/shelf_types.h" | 9 #include "ash/shelf_types.h" |
| 10 #include "ash/system/user/login_status.h" | 10 #include "ash/system/user/login_status.h" |
| (...skipping 14 matching lines...) Expand all Loading... | |
| 25 | 25 |
| 26 namespace views { | 26 namespace views { |
| 27 namespace corewm { | 27 namespace corewm { |
| 28 class InputMethodEventFilter; | 28 class InputMethodEventFilter; |
| 29 class RootWindowEventFilter; | 29 class RootWindowEventFilter; |
| 30 } | 30 } |
| 31 } | 31 } |
| 32 | 32 |
| 33 namespace ash { | 33 namespace ash { |
| 34 class Launcher; | 34 class Launcher; |
| 35 class SystemTray; | |
| 35 class ToplevelWindowEventHandler; | 36 class ToplevelWindowEventHandler; |
| 36 | 37 |
| 37 namespace internal { | 38 namespace internal { |
| 38 | 39 |
| 39 class BootSplashScreen; | 40 class BootSplashScreen; |
| 40 class PanelLayoutManager; | 41 class PanelLayoutManager; |
| 41 class RootWindowLayoutManager; | 42 class RootWindowLayoutManager; |
| 42 class ScreenDimmer; | 43 class ScreenDimmer; |
| 43 class ShelfLayoutManager; | 44 class ShelfLayoutManager; |
| 44 class StatusAreaWidget; | 45 class StatusAreaWidget; |
| (...skipping 10 matching lines...) Expand all Loading... | |
| 55 public: | 56 public: |
| 56 explicit RootWindowController(aura::RootWindow* root_window); | 57 explicit RootWindowController(aura::RootWindow* root_window); |
| 57 ~RootWindowController(); | 58 ~RootWindowController(); |
| 58 | 59 |
| 59 // Returns a RootWindowController that has a launcher for given | 60 // Returns a RootWindowController that has a launcher for given |
| 60 // |window|. This returns the RootWindowController for the |window|'s | 61 // |window|. This returns the RootWindowController for the |window|'s |
| 61 // root window when multiple launcher mode is enabled, or the primary | 62 // root window when multiple launcher mode is enabled, or the primary |
| 62 // RootWindowController otherwise. | 63 // RootWindowController otherwise. |
| 63 static RootWindowController* ForLauncher(aura::Window* window); | 64 static RootWindowController* ForLauncher(aura::Window* window); |
| 64 | 65 |
| 66 // Returns a RootWnidowController of the window's root window. | |
|
sky
2012/12/07 23:53:00
RootWindowController
oshima
2012/12/08 00:00:45
Done.
| |
| 67 static RootWindowController* ForWindow(aura::Window* window); | |
| 68 | |
| 69 // Returns the RootWindowController of the active root window. | |
| 70 static internal::RootWindowController* ForActiveRootWindow(); | |
| 71 | |
| 65 aura::RootWindow* root_window() { return root_window_.get(); } | 72 aura::RootWindow* root_window() { return root_window_.get(); } |
| 66 | 73 |
| 67 RootWindowLayoutManager* root_window_layout() { return root_window_layout_; } | 74 RootWindowLayoutManager* root_window_layout() { return root_window_layout_; } |
| 68 | 75 |
| 69 WorkspaceController* workspace_controller() { | 76 WorkspaceController* workspace_controller() { |
| 70 return workspace_controller_.get(); | 77 return workspace_controller_.get(); |
| 71 } | 78 } |
| 72 | 79 |
| 73 ScreenDimmer* screen_dimmer() { return screen_dimmer_.get(); } | 80 ScreenDimmer* screen_dimmer() { return screen_dimmer_.get(); } |
| 74 | 81 |
| 75 Launcher* launcher() { return launcher_.get(); } | 82 Launcher* launcher() { return launcher_.get(); } |
| 76 | 83 |
| 77 ShelfLayoutManager* shelf() const { return shelf_; } | 84 ShelfLayoutManager* shelf() const { return shelf_; } |
| 78 | 85 |
| 79 StatusAreaWidget* status_area_widget() const { | 86 StatusAreaWidget* status_area_widget() { |
| 80 return status_area_widget_; | 87 return status_area_widget_; |
| 81 } | 88 } |
| 82 | 89 |
| 90 // Returns the system tray on this root window. Note that | |
| 91 // Calling this on the root window that doesn't have a launcher will | |
|
sky
2012/12/07 23:53:00
Calling -> calling
oshima
2012/12/08 00:00:45
Done.
| |
| 92 // lead to a crash. | |
| 93 SystemTray* GetSystemTray(); | |
| 94 | |
| 83 // Shows context menu at the |location_in_screen|. This uses | 95 // Shows context menu at the |location_in_screen|. This uses |
| 84 // |ShellDelegate::CreateContextMenu| to define the content of the menu. | 96 // |ShellDelegate::CreateContextMenu| to define the content of the menu. |
| 85 void ShowContextMenu(const gfx::Point& location_in_screen); | 97 void ShowContextMenu(const gfx::Point& location_in_screen); |
| 86 | 98 |
| 87 // Returns the layout-manager for the appropriate modal-container. If the | 99 // Returns the layout-manager for the appropriate modal-container. If the |
| 88 // window is inside the lockscreen modal container, then the layout manager | 100 // window is inside the lockscreen modal container, then the layout manager |
| 89 // for that is returned. Otherwise the layout manager for the default modal | 101 // for that is returned. Otherwise the layout manager for the default modal |
| 90 // container is returned. | 102 // container is returned. |
| 91 // If no window is specified (i.e. |window| is NULL), then the lockscreen | 103 // If no window is specified (i.e. |window| is NULL), then the lockscreen |
| 92 // modal container is used if the screen is currently locked. Otherwise, the | 104 // modal container is used if the screen is currently locked. Otherwise, the |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 185 scoped_ptr<ToplevelWindowEventHandler> modal_container_handler_; | 197 scoped_ptr<ToplevelWindowEventHandler> modal_container_handler_; |
| 186 scoped_ptr<ToplevelWindowEventHandler> lock_modal_container_handler_; | 198 scoped_ptr<ToplevelWindowEventHandler> lock_modal_container_handler_; |
| 187 | 199 |
| 188 DISALLOW_COPY_AND_ASSIGN(RootWindowController); | 200 DISALLOW_COPY_AND_ASSIGN(RootWindowController); |
| 189 }; | 201 }; |
| 190 | 202 |
| 191 } // namespace internal | 203 } // namespace internal |
| 192 } // ash | 204 } // ash |
| 193 | 205 |
| 194 #endif // ASH_ROOT_WINDOW_CONTROLLER_H_ | 206 #endif // ASH_ROOT_WINDOW_CONTROLLER_H_ |
| OLD | NEW |