| 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 #include "ash/aura/wm_shell_aura.h" | 5 #include "ash/aura/wm_shell_aura.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "ash/accelerators/accelerator_controller_delegate_aura.h" | 9 #include "ash/accelerators/accelerator_controller_delegate_aura.h" |
| 10 #include "ash/aura/key_event_watcher_aura.h" | 10 #include "ash/aura/key_event_watcher_aura.h" |
| (...skipping 13 matching lines...) Expand all Loading... |
| 24 #include "ash/laser/laser_pointer_controller.h" | 24 #include "ash/laser/laser_pointer_controller.h" |
| 25 #include "ash/magnifier/partial_magnification_controller.h" | 25 #include "ash/magnifier/partial_magnification_controller.h" |
| 26 #include "ash/metrics/task_switch_metrics_recorder.h" | 26 #include "ash/metrics/task_switch_metrics_recorder.h" |
| 27 #include "ash/public/cpp/config.h" | 27 #include "ash/public/cpp/config.h" |
| 28 #include "ash/shared/immersive_fullscreen_controller.h" | 28 #include "ash/shared/immersive_fullscreen_controller.h" |
| 29 #include "ash/shell.h" | 29 #include "ash/shell.h" |
| 30 #include "ash/touch/touch_uma.h" | 30 #include "ash/touch/touch_uma.h" |
| 31 #include "ash/virtual_keyboard_controller.h" | 31 #include "ash/virtual_keyboard_controller.h" |
| 32 #include "ash/wm/drag_window_resizer.h" | 32 #include "ash/wm/drag_window_resizer.h" |
| 33 #include "ash/wm/maximize_mode/maximize_mode_event_handler_aura.h" | 33 #include "ash/wm/maximize_mode/maximize_mode_event_handler_aura.h" |
| 34 #include "ash/wm/screen_pinning_controller.h" | |
| 35 #include "ash/wm/window_cycle_event_filter_aura.h" | 34 #include "ash/wm/window_cycle_event_filter_aura.h" |
| 36 #include "ash/wm/window_util.h" | 35 #include "ash/wm/window_util.h" |
| 37 #include "ash/wm/workspace/workspace_event_handler_aura.h" | 36 #include "ash/wm/workspace/workspace_event_handler_aura.h" |
| 38 #include "base/memory/ptr_util.h" | 37 #include "base/memory/ptr_util.h" |
| 39 #include "ui/aura/client/capture_client.h" | 38 #include "ui/aura/client/capture_client.h" |
| 40 #include "ui/aura/client/focus_client.h" | 39 #include "ui/aura/client/focus_client.h" |
| 41 #include "ui/aura/env.h" | 40 #include "ui/aura/env.h" |
| 42 #include "ui/display/manager/display_manager.h" | 41 #include "ui/display/manager/display_manager.h" |
| 43 | 42 |
| 44 #if defined(USE_X11) | 43 #if defined(USE_X11) |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 134 display::DisplayManager::UNIFIED; | 133 display::DisplayManager::UNIFIED; |
| 135 } | 134 } |
| 136 | 135 |
| 137 void WmShellAura::SetDisplayWorkAreaInsets(WmWindow* window, | 136 void WmShellAura::SetDisplayWorkAreaInsets(WmWindow* window, |
| 138 const gfx::Insets& insets) { | 137 const gfx::Insets& insets) { |
| 139 Shell::GetInstance() | 138 Shell::GetInstance() |
| 140 ->window_tree_host_manager() | 139 ->window_tree_host_manager() |
| 141 ->UpdateWorkAreaOfDisplayNearestWindow(window->aura_window(), insets); | 140 ->UpdateWorkAreaOfDisplayNearestWindow(window->aura_window(), insets); |
| 142 } | 141 } |
| 143 | 142 |
| 144 bool WmShellAura::IsPinned() { | |
| 145 return Shell::GetInstance()->screen_pinning_controller()->IsPinned(); | |
| 146 } | |
| 147 | |
| 148 void WmShellAura::SetPinnedWindow(WmWindow* window) { | |
| 149 return Shell::GetInstance()->screen_pinning_controller()->SetPinnedWindow( | |
| 150 window); | |
| 151 } | |
| 152 | |
| 153 void WmShellAura::LockCursor() { | 143 void WmShellAura::LockCursor() { |
| 154 Shell::GetInstance()->cursor_manager()->LockCursor(); | 144 Shell::GetInstance()->cursor_manager()->LockCursor(); |
| 155 } | 145 } |
| 156 | 146 |
| 157 void WmShellAura::UnlockCursor() { | 147 void WmShellAura::UnlockCursor() { |
| 158 Shell::GetInstance()->cursor_manager()->UnlockCursor(); | 148 Shell::GetInstance()->cursor_manager()->UnlockCursor(); |
| 159 } | 149 } |
| 160 | 150 |
| 161 bool WmShellAura::IsMouseEventsEnabled() { | 151 bool WmShellAura::IsMouseEventsEnabled() { |
| 162 return Shell::GetInstance()->cursor_manager()->IsMouseEventsEnabled(); | 152 return Shell::GetInstance()->cursor_manager()->IsMouseEventsEnabled(); |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 300 for (auto& observer : display_observers_) | 290 for (auto& observer : display_observers_) |
| 301 observer.OnDisplayConfigurationChanging(); | 291 observer.OnDisplayConfigurationChanging(); |
| 302 } | 292 } |
| 303 | 293 |
| 304 void WmShellAura::OnDisplayConfigurationChanged() { | 294 void WmShellAura::OnDisplayConfigurationChanged() { |
| 305 for (auto& observer : display_observers_) | 295 for (auto& observer : display_observers_) |
| 306 observer.OnDisplayConfigurationChanged(); | 296 observer.OnDisplayConfigurationChanged(); |
| 307 } | 297 } |
| 308 | 298 |
| 309 } // namespace ash | 299 } // namespace ash |
| OLD | NEW |