| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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_COMMON_WM_ROOT_WINDOW_CONTROLLER_H_ | 5 #ifndef ASH_COMMON_WM_ROOT_WINDOW_CONTROLLER_H_ |
| 6 #define ASH_COMMON_WM_ROOT_WINDOW_CONTROLLER_H_ | 6 #define ASH_COMMON_WM_ROOT_WINDOW_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include "ash/ash_export.h" | 8 #include "ash/ash_export.h" |
| 9 #include "ash/common/wm/workspace/workspace_types.h" | 9 #include "ash/common/wm/workspace/workspace_types.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "ui/views/widget/widget.h" | 11 #include "ui/views/widget/widget.h" |
| 12 | 12 |
| 13 namespace gfx { | 13 namespace gfx { |
| 14 class Point; | 14 class Point; |
| 15 } | 15 } |
| 16 | 16 |
| 17 namespace ash { | 17 namespace ash { |
| 18 | 18 |
| 19 class AlwaysOnTopController; | 19 class AlwaysOnTopController; |
| 20 class AnimatingWallpaperWidgetController; | 20 class AnimatingWallpaperWidgetController; |
| 21 class SystemModalContainerLayoutManager; |
| 21 class WallpaperWidgetController; | 22 class WallpaperWidgetController; |
| 22 class WmShelf; | 23 class WmShelf; |
| 23 class WmShell; | 24 class WmShell; |
| 24 class WmWindow; | 25 class WmWindow; |
| 25 class WorkspaceController; | 26 class WorkspaceController; |
| 26 | 27 |
| 27 namespace wm { | 28 namespace wm { |
| 28 class RootWindowLayoutManager; | 29 class RootWindowLayoutManager; |
| 29 } | 30 } |
| 30 | 31 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 48 } | 49 } |
| 49 void SetAnimatingWallpaperWidgetController( | 50 void SetAnimatingWallpaperWidgetController( |
| 50 AnimatingWallpaperWidgetController* controller); | 51 AnimatingWallpaperWidgetController* controller); |
| 51 | 52 |
| 52 WorkspaceController* workspace_controller() { | 53 WorkspaceController* workspace_controller() { |
| 53 return workspace_controller_.get(); | 54 return workspace_controller_.get(); |
| 54 } | 55 } |
| 55 | 56 |
| 56 wm::WorkspaceWindowState GetWorkspaceWindowState(); | 57 wm::WorkspaceWindowState GetWorkspaceWindowState(); |
| 57 | 58 |
| 59 // Returns the layout manager for the appropriate modal-container. If the |
| 60 // window is inside the lockscreen modal container, then the layout manager |
| 61 // for that is returned. Otherwise the layout manager for the default modal |
| 62 // container is returned. |
| 63 // If no window is specified (i.e. |window| is null), then the lockscreen |
| 64 // modal container is used if the screen is currently locked. Otherwise, the |
| 65 // default modal container is used. |
| 66 SystemModalContainerLayoutManager* GetSystemModalLayoutManager( |
| 67 WmWindow* window); |
| 68 |
| 58 virtual bool HasShelf() = 0; | 69 virtual bool HasShelf() = 0; |
| 59 | 70 |
| 60 virtual WmShell* GetShell() = 0; | 71 virtual WmShell* GetShell() = 0; |
| 61 | 72 |
| 62 virtual AlwaysOnTopController* GetAlwaysOnTopController() = 0; | 73 virtual AlwaysOnTopController* GetAlwaysOnTopController() = 0; |
| 63 | 74 |
| 64 virtual WmShelf* GetShelf() = 0; | 75 virtual WmShelf* GetShelf() = 0; |
| 65 | 76 |
| 66 // Returns the window associated with this WmRootWindowController. | 77 // Returns the window associated with this WmRootWindowController. |
| 67 virtual WmWindow* GetWindow() = 0; | 78 virtual WmWindow* GetWindow() = 0; |
| 68 | 79 |
| 80 // Gets the WmWindow whose shell window id is |container_id|. |
| 81 WmWindow* GetContainer(int container_id); |
| 82 const WmWindow* GetContainer(int container_id) const; |
| 83 |
| 69 // Configures |init_params| prior to initializing |widget|. | 84 // Configures |init_params| prior to initializing |widget|. |
| 70 // |shell_container_id| is the id of the container to parent |widget| to. | 85 // |shell_container_id| is the id of the container to parent |widget| to. |
| 71 virtual void ConfigureWidgetInitParamsForContainer( | 86 virtual void ConfigureWidgetInitParamsForContainer( |
| 72 views::Widget* widget, | 87 views::Widget* widget, |
| 73 int shell_container_id, | 88 int shell_container_id, |
| 74 views::Widget::InitParams* init_params) = 0; | 89 views::Widget::InitParams* init_params) = 0; |
| 75 | 90 |
| 76 // Returns the window events will be targeted at for the specified location | 91 // Returns the window events will be targeted at for the specified location |
| 77 // (in screen coordinates). | 92 // (in screen coordinates). |
| 78 // | 93 // |
| (...skipping 28 matching lines...) Expand all Loading... |
| 107 std::unique_ptr<AnimatingWallpaperWidgetController> | 122 std::unique_ptr<AnimatingWallpaperWidgetController> |
| 108 animating_wallpaper_widget_controller_; | 123 animating_wallpaper_widget_controller_; |
| 109 std::unique_ptr<WorkspaceController> workspace_controller_; | 124 std::unique_ptr<WorkspaceController> workspace_controller_; |
| 110 | 125 |
| 111 DISALLOW_COPY_AND_ASSIGN(WmRootWindowController); | 126 DISALLOW_COPY_AND_ASSIGN(WmRootWindowController); |
| 112 }; | 127 }; |
| 113 | 128 |
| 114 } // namespace ash | 129 } // namespace ash |
| 115 | 130 |
| 116 #endif // ASH_COMMON_WM_ROOT_WINDOW_CONTROLLER_H_ | 131 #endif // ASH_COMMON_WM_ROOT_WINDOW_CONTROLLER_H_ |
| OLD | NEW |