| 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_SHELL_H_ | 5 #ifndef ASH_SHELL_H_ |
| 6 #define ASH_SHELL_H_ | 6 #define ASH_SHELL_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 229 | 229 |
| 230 // Returns the primary root Window. The primary root Window is the one that | 230 // Returns the primary root Window. The primary root Window is the one that |
| 231 // has a launcher. | 231 // has a launcher. |
| 232 static aura::Window* GetPrimaryRootWindow(); | 232 static aura::Window* GetPrimaryRootWindow(); |
| 233 | 233 |
| 234 // Returns the root window that newly created windows should be added to. | 234 // Returns the root window that newly created windows should be added to. |
| 235 // Value can be temporarily overridden using ScopedRootWindowForNewWindows. | 235 // Value can be temporarily overridden using ScopedRootWindowForNewWindows. |
| 236 // NOTE: this returns the root, newly created window should be added to the | 236 // NOTE: this returns the root, newly created window should be added to the |
| 237 // appropriate container in the returned window. | 237 // appropriate container in the returned window. |
| 238 static aura::Window* GetRootWindowForNewWindows(); | 238 static aura::Window* GetRootWindowForNewWindows(); |
| 239 static WmWindow* GetWmRootWindowForNewWindows(); | |
| 240 | 239 |
| 241 // Returns all root windows. | 240 // Returns all root windows. |
| 242 static aura::Window::Windows GetAllRootWindows(); | 241 static aura::Window::Windows GetAllRootWindows(); |
| 243 | 242 |
| 244 static aura::Window* GetContainer(aura::Window* root_window, | 243 static aura::Window* GetContainer(aura::Window* root_window, |
| 245 int container_id); | 244 int container_id); |
| 246 static const aura::Window* GetContainer(const aura::Window* root_window, | 245 static const aura::Window* GetContainer(const aura::Window* root_window, |
| 247 int container_id); | 246 int container_id); |
| 248 | 247 |
| 249 // TODO(sky): move this and WindowManagerClient into ShellMash that is owned | 248 // TODO(sky): move this and WindowManagerClient into ShellMash that is owned |
| (...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 507 | 506 |
| 508 UserMetricsRecorder* metrics() { return user_metrics_recorder_.get(); } | 507 UserMetricsRecorder* metrics() { return user_metrics_recorder_.get(); } |
| 509 | 508 |
| 510 void SetTouchHudProjectionEnabled(bool enabled); | 509 void SetTouchHudProjectionEnabled(bool enabled); |
| 511 | 510 |
| 512 bool is_touch_hud_projection_enabled() const { | 511 bool is_touch_hud_projection_enabled() const { |
| 513 return is_touch_hud_projection_enabled_; | 512 return is_touch_hud_projection_enabled_; |
| 514 } | 513 } |
| 515 | 514 |
| 516 // NOTE: Prefer ScopedRootWindowForNewWindows when setting temporarily. | 515 // NOTE: Prefer ScopedRootWindowForNewWindows when setting temporarily. |
| 517 void set_root_window_for_new_windows(WmWindow* root) { | 516 void set_root_window_for_new_windows(aura::Window* root) { |
| 518 root_window_for_new_windows_ = root; | 517 root_window_for_new_windows_ = root; |
| 519 } | 518 } |
| 520 | 519 |
| 521 // Creates instance of FirstRunHelper. Caller is responsible for deleting | 520 // Creates instance of FirstRunHelper. Caller is responsible for deleting |
| 522 // returned object. | 521 // returned object. |
| 523 ash::FirstRunHelper* CreateFirstRunHelper(); | 522 ash::FirstRunHelper* CreateFirstRunHelper(); |
| 524 | 523 |
| 525 void SetLargeCursorSizeInDip(int large_cursor_size_in_dip); | 524 void SetLargeCursorSizeInDip(int large_cursor_size_in_dip); |
| 526 | 525 |
| 527 // Toggles cursor compositing on/off. Native cursor is disabled when cursor | 526 // Toggles cursor compositing on/off. Native cursor is disabled when cursor |
| (...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 808 | 807 |
| 809 // Cursor may be hidden on certain key events in Chrome OS, whereas we never | 808 // Cursor may be hidden on certain key events in Chrome OS, whereas we never |
| 810 // hide the cursor on Windows. | 809 // hide the cursor on Windows. |
| 811 std::unique_ptr<::wm::CursorManager> cursor_manager_; | 810 std::unique_ptr<::wm::CursorManager> cursor_manager_; |
| 812 | 811 |
| 813 // For testing only: simulate that a modal window is open | 812 // For testing only: simulate that a modal window is open |
| 814 bool simulate_modal_window_open_for_testing_; | 813 bool simulate_modal_window_open_for_testing_; |
| 815 | 814 |
| 816 bool is_touch_hud_projection_enabled_; | 815 bool is_touch_hud_projection_enabled_; |
| 817 | 816 |
| 818 // See comment for GetWmRootWindowForNewWindows(). | 817 // See comment for GetRootWindowForNewWindows(). |
| 819 WmWindow* root_window_for_new_windows_ = nullptr; | 818 aura::Window* root_window_for_new_windows_ = nullptr; |
| 820 WmWindow* scoped_root_window_for_new_windows_ = nullptr; | 819 aura::Window* scoped_root_window_for_new_windows_ = nullptr; |
| 821 | 820 |
| 822 // Injected content::GPUDataManager support. | 821 // Injected content::GPUDataManager support. |
| 823 std::unique_ptr<GPUSupport> gpu_support_; | 822 std::unique_ptr<GPUSupport> gpu_support_; |
| 824 | 823 |
| 825 std::unique_ptr<ImmersiveHandlerFactoryAsh> immersive_handler_factory_; | 824 std::unique_ptr<ImmersiveHandlerFactoryAsh> immersive_handler_factory_; |
| 826 | 825 |
| 827 std::unique_ptr<AppListDelegateImpl> app_list_delegate_impl_; | 826 std::unique_ptr<AppListDelegateImpl> app_list_delegate_impl_; |
| 828 | 827 |
| 829 base::ObserverList<ShellObserver> shell_observers_; | 828 base::ObserverList<ShellObserver> shell_observers_; |
| 830 | 829 |
| 831 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; | 830 scoped_refptr<base::SequencedWorkerPool> blocking_pool_; |
| 832 | 831 |
| 833 DISALLOW_COPY_AND_ASSIGN(Shell); | 832 DISALLOW_COPY_AND_ASSIGN(Shell); |
| 834 }; | 833 }; |
| 835 | 834 |
| 836 } // namespace ash | 835 } // namespace ash |
| 837 | 836 |
| 838 #endif // ASH_SHELL_H_ | 837 #endif // ASH_SHELL_H_ |
| OLD | NEW |