OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/display/display_change_observer_chromeos.h" | 5 #include "ash/display/display_change_observer_chromeos.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <string> | 10 #include <string> |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
260 } | 260 } |
261 | 261 |
262 AssociateTouchscreens( | 262 AssociateTouchscreens( |
263 &displays, ui::DeviceDataManager::GetInstance()->touchscreen_devices()); | 263 &displays, ui::DeviceDataManager::GetInstance()->touchscreen_devices()); |
264 // DisplayManager can be null during the boot. | 264 // DisplayManager can be null during the boot. |
265 Shell::GetInstance()->display_manager()->OnNativeDisplaysChanged(displays); | 265 Shell::GetInstance()->display_manager()->OnNativeDisplaysChanged(displays); |
266 | 266 |
267 // For the purposes of user activity detection, ignore synthetic mouse events | 267 // For the purposes of user activity detection, ignore synthetic mouse events |
268 // that are triggered by screen resizes: http://crbug.com/360634 | 268 // that are triggered by screen resizes: http://crbug.com/360634 |
269 ::wm::UserActivityDetector* user_activity_detector = | 269 ::wm::UserActivityDetector* user_activity_detector = |
270 Shell::GetInstance()->user_activity_detector(); | 270 ::wm::UserActivityDetector::Get(); |
271 if (user_activity_detector) | 271 if (user_activity_detector) |
272 user_activity_detector->OnDisplayPowerChanging(); | 272 user_activity_detector->OnDisplayPowerChanging(); |
273 } | 273 } |
274 | 274 |
275 void DisplayChangeObserver::OnAppTerminating() { | 275 void DisplayChangeObserver::OnAppTerminating() { |
276 #if defined(USE_ASH) | 276 #if defined(USE_ASH) |
277 // Stop handling display configuration events once the shutdown | 277 // Stop handling display configuration events once the shutdown |
278 // process starts. crbug.com/177014. | 278 // process starts. crbug.com/177014. |
279 Shell::GetInstance()->display_configurator()->PrepareForExit(); | 279 Shell::GetInstance()->display_configurator()->PrepareForExit(); |
280 #endif | 280 #endif |
(...skipping 10 matching lines...) Expand all Loading... |
291 | 291 |
292 void DisplayChangeObserver::OnTouchscreenDeviceConfigurationChanged() { | 292 void DisplayChangeObserver::OnTouchscreenDeviceConfigurationChanged() { |
293 OnDisplayModeChanged( | 293 OnDisplayModeChanged( |
294 Shell::GetInstance()->display_configurator()->cached_displays()); | 294 Shell::GetInstance()->display_configurator()->cached_displays()); |
295 } | 295 } |
296 | 296 |
297 void DisplayChangeObserver::OnKeyboardDeviceConfigurationChanged() { | 297 void DisplayChangeObserver::OnKeyboardDeviceConfigurationChanged() { |
298 } | 298 } |
299 | 299 |
300 } // namespace ash | 300 } // namespace ash |
OLD | NEW |