Chromium Code Reviews| 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_SHELL_H_ | 5 #ifndef ASH_COMMON_WM_SHELL_H_ |
| 6 #define ASH_COMMON_WM_SHELL_H_ | 6 #define ASH_COMMON_WM_SHELL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| 11 #include <vector> | 11 #include <vector> |
| 12 | 12 |
| 13 #include "ash/ash_export.h" | 13 #include "ash/ash_export.h" |
| 14 #include "ash/common/media_delegate.h" | 14 #include "ash/common/media_delegate.h" |
| 15 #include "ash/common/metrics/gesture_action_type.h" | 15 #include "ash/common/metrics/gesture_action_type.h" |
| 16 #include "ash/common/metrics/user_metrics_action.h" | 16 #include "ash/common/metrics/user_metrics_action.h" |
| 17 #include "ash/common/shelf/shelf_controller.h" | |
| 17 #include "ash/common/wm/lock_state_observer.h" | 18 #include "ash/common/wm/lock_state_observer.h" |
| 18 #include "base/observer_list.h" | 19 #include "base/observer_list.h" |
| 19 #include "ui/base/ui_base_types.h" | 20 #include "ui/base/ui_base_types.h" |
| 20 #include "ui/compositor/layer_type.h" | 21 #include "ui/compositor/layer_type.h" |
| 21 #include "ui/wm/public/window_types.h" | 22 #include "ui/wm/public/window_types.h" |
| 22 | 23 |
| 23 namespace base { | 24 namespace base { |
| 24 class SequencedWorkerPool; | 25 class SequencedWorkerPool; |
| 25 } | 26 } |
| 26 | 27 |
| (...skipping 26 matching lines...) Expand all Loading... | |
| 53 class ImmersiveFullscreenController; | 54 class ImmersiveFullscreenController; |
| 54 class KeyEventWatcher; | 55 class KeyEventWatcher; |
| 55 class KeyboardBrightnessControlDelegate; | 56 class KeyboardBrightnessControlDelegate; |
| 56 class KeyboardUI; | 57 class KeyboardUI; |
| 57 class MaximizeModeController; | 58 class MaximizeModeController; |
| 58 class MruWindowTracker; | 59 class MruWindowTracker; |
| 59 class NewWindowDelegate; | 60 class NewWindowDelegate; |
| 60 class PaletteDelegate; | 61 class PaletteDelegate; |
| 61 class ScopedDisableInternalMouseAndKeyboard; | 62 class ScopedDisableInternalMouseAndKeyboard; |
| 62 class SessionStateDelegate; | 63 class SessionStateDelegate; |
| 64 class ShelfController; | |
| 63 class ShelfDelegate; | 65 class ShelfDelegate; |
| 64 class ShelfModel; | 66 class ShelfModel; |
| 65 class ShelfWindowWatcher; | 67 class ShelfWindowWatcher; |
| 66 class ShellDelegate; | 68 class ShellDelegate; |
| 67 class ShellObserver; | 69 class ShellObserver; |
| 68 class SystemTrayDelegate; | 70 class SystemTrayDelegate; |
| 69 class SystemTrayController; | 71 class SystemTrayController; |
| 70 class SystemTrayNotifier; | 72 class SystemTrayNotifier; |
| 71 class ToastManager; | 73 class ToastManager; |
| 72 class WallpaperController; | 74 class WallpaperController; |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 139 return new_window_delegate_.get(); | 141 return new_window_delegate_.get(); |
| 140 } | 142 } |
| 141 | 143 |
| 142 // NOTE: Prefer ScopedRootWindowForNewWindows when setting temporarily. | 144 // NOTE: Prefer ScopedRootWindowForNewWindows when setting temporarily. |
| 143 void set_root_window_for_new_windows(WmWindow* root) { | 145 void set_root_window_for_new_windows(WmWindow* root) { |
| 144 root_window_for_new_windows_ = root; | 146 root_window_for_new_windows_ = root; |
| 145 } | 147 } |
| 146 | 148 |
| 147 PaletteDelegate* palette_delegate() { return palette_delegate_.get(); } | 149 PaletteDelegate* palette_delegate() { return palette_delegate_.get(); } |
| 148 | 150 |
| 151 ShelfController* shelf_controller() { return shelf_controller_.get(); } | |
| 152 | |
| 149 ShelfDelegate* shelf_delegate() { return shelf_delegate_.get(); } | 153 ShelfDelegate* shelf_delegate() { return shelf_delegate_.get(); } |
| 150 | 154 |
| 151 ShelfModel* shelf_model() { return shelf_model_.get(); } | 155 ShelfModel* shelf_model() { return shelf_controller_->model(); } |
|
James Cook
2016/10/10 17:18:13
drive by: I would implement this in the .cc file.
msw
2016/10/11 00:44:06
Done.
| |
| 152 | 156 |
| 153 SystemTrayController* system_tray_controller() { | 157 SystemTrayController* system_tray_controller() { |
| 154 return system_tray_controller_.get(); | 158 return system_tray_controller_.get(); |
| 155 } | 159 } |
| 156 | 160 |
| 157 SystemTrayNotifier* system_tray_notifier() { | 161 SystemTrayNotifier* system_tray_notifier() { |
| 158 return system_tray_notifier_.get(); | 162 return system_tray_notifier_.get(); |
| 159 } | 163 } |
| 160 | 164 |
| 161 SystemTrayDelegate* system_tray_delegate() { | 165 SystemTrayDelegate* system_tray_delegate() { |
| (...skipping 304 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 466 std::unique_ptr<FocusCycler> focus_cycler_; | 470 std::unique_ptr<FocusCycler> focus_cycler_; |
| 467 std::unique_ptr<ImmersiveContextAsh> immersive_context_; | 471 std::unique_ptr<ImmersiveContextAsh> immersive_context_; |
| 468 std::unique_ptr<KeyboardBrightnessControlDelegate> | 472 std::unique_ptr<KeyboardBrightnessControlDelegate> |
| 469 keyboard_brightness_control_delegate_; | 473 keyboard_brightness_control_delegate_; |
| 470 std::unique_ptr<KeyboardUI> keyboard_ui_; | 474 std::unique_ptr<KeyboardUI> keyboard_ui_; |
| 471 std::unique_ptr<MaximizeModeController> maximize_mode_controller_; | 475 std::unique_ptr<MaximizeModeController> maximize_mode_controller_; |
| 472 std::unique_ptr<MediaDelegate> media_delegate_; | 476 std::unique_ptr<MediaDelegate> media_delegate_; |
| 473 std::unique_ptr<MruWindowTracker> mru_window_tracker_; | 477 std::unique_ptr<MruWindowTracker> mru_window_tracker_; |
| 474 std::unique_ptr<NewWindowDelegate> new_window_delegate_; | 478 std::unique_ptr<NewWindowDelegate> new_window_delegate_; |
| 475 std::unique_ptr<PaletteDelegate> palette_delegate_; | 479 std::unique_ptr<PaletteDelegate> palette_delegate_; |
| 480 std::unique_ptr<ShelfController> shelf_controller_; | |
| 476 std::unique_ptr<ShelfDelegate> shelf_delegate_; | 481 std::unique_ptr<ShelfDelegate> shelf_delegate_; |
| 477 std::unique_ptr<ShelfModel> shelf_model_; | |
| 478 std::unique_ptr<ShelfWindowWatcher> shelf_window_watcher_; | 482 std::unique_ptr<ShelfWindowWatcher> shelf_window_watcher_; |
| 479 std::unique_ptr<SystemTrayController> system_tray_controller_; | 483 std::unique_ptr<SystemTrayController> system_tray_controller_; |
| 480 std::unique_ptr<SystemTrayNotifier> system_tray_notifier_; | 484 std::unique_ptr<SystemTrayNotifier> system_tray_notifier_; |
| 481 std::unique_ptr<SystemTrayDelegate> system_tray_delegate_; | 485 std::unique_ptr<SystemTrayDelegate> system_tray_delegate_; |
| 482 std::unique_ptr<ToastManager> toast_manager_; | 486 std::unique_ptr<ToastManager> toast_manager_; |
| 483 std::unique_ptr<WallpaperController> wallpaper_controller_; | 487 std::unique_ptr<WallpaperController> wallpaper_controller_; |
| 484 std::unique_ptr<WallpaperDelegate> wallpaper_delegate_; | 488 std::unique_ptr<WallpaperDelegate> wallpaper_delegate_; |
| 485 std::unique_ptr<WindowCycleController> window_cycle_controller_; | 489 std::unique_ptr<WindowCycleController> window_cycle_controller_; |
| 486 std::unique_ptr<WindowSelectorController> window_selector_controller_; | 490 std::unique_ptr<WindowSelectorController> window_selector_controller_; |
| 487 | 491 |
| 488 base::ObserverList<LockStateObserver> lock_state_observers_; | 492 base::ObserverList<LockStateObserver> lock_state_observers_; |
| 489 | 493 |
| 490 // See comment for GetRootWindowForNewWindows(). | 494 // See comment for GetRootWindowForNewWindows(). |
| 491 WmWindow* root_window_for_new_windows_ = nullptr; | 495 WmWindow* root_window_for_new_windows_ = nullptr; |
| 492 WmWindow* scoped_root_window_for_new_windows_ = nullptr; | 496 WmWindow* scoped_root_window_for_new_windows_ = nullptr; |
| 493 | 497 |
| 494 bool simulate_modal_window_open_for_testing_ = false; | 498 bool simulate_modal_window_open_for_testing_ = false; |
| 495 | 499 |
| 496 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; | 500 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; |
| 497 | 501 |
| 498 #if defined(OS_CHROMEOS) | 502 #if defined(OS_CHROMEOS) |
| 499 std::unique_ptr<LogoutConfirmationController> logout_confirmation_controller_; | 503 std::unique_ptr<LogoutConfirmationController> logout_confirmation_controller_; |
| 500 #endif | 504 #endif |
| 501 }; | 505 }; |
| 502 | 506 |
| 503 } // namespace ash | 507 } // namespace ash |
| 504 | 508 |
| 505 #endif // ASH_COMMON_WM_SHELL_H_ | 509 #endif // ASH_COMMON_WM_SHELL_H_ |
| OLD | NEW |