| 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 #include "ash/shell.h" | 5 #include "ash/shell.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 | 111 |
| 112 #if defined(OS_CHROMEOS) | 112 #if defined(OS_CHROMEOS) |
| 113 #if defined(USE_X11) | 113 #if defined(USE_X11) |
| 114 #include "ui/gfx/x/x11_types.h" // nogncheck | 114 #include "ui/gfx/x/x11_types.h" // nogncheck |
| 115 #endif // defined(USE_X11) | 115 #endif // defined(USE_X11) |
| 116 #include "ash/accelerators/magnifier_key_scroller.h" | 116 #include "ash/accelerators/magnifier_key_scroller.h" |
| 117 #include "ash/accelerators/spoken_feedback_toggler.h" | 117 #include "ash/accelerators/spoken_feedback_toggler.h" |
| 118 #include "ash/common/ash_constants.h" | 118 #include "ash/common/ash_constants.h" |
| 119 #include "ash/common/system/chromeos/bluetooth/bluetooth_notification_controller
.h" | 119 #include "ash/common/system/chromeos/bluetooth/bluetooth_notification_controller
.h" |
| 120 #include "ash/common/system/chromeos/power/power_status.h" | 120 #include "ash/common/system/chromeos/power/power_status.h" |
| 121 #include "ash/display/display_change_observer_chromeos.h" | |
| 122 #include "ash/display/display_color_manager_chromeos.h" | 121 #include "ash/display/display_color_manager_chromeos.h" |
| 123 #include "ash/display/display_error_observer_chromeos.h" | 122 #include "ash/display/display_error_observer_chromeos.h" |
| 124 #include "ash/display/projecting_observer_chromeos.h" | 123 #include "ash/display/projecting_observer_chromeos.h" |
| 125 #include "ash/display/resolution_notification_controller.h" | 124 #include "ash/display/resolution_notification_controller.h" |
| 126 #include "ash/display/screen_orientation_controller_chromeos.h" | 125 #include "ash/display/screen_orientation_controller_chromeos.h" |
| 127 #include "ash/display/shutdown_observer_chromeos.h" | 126 #include "ash/display/shutdown_observer_chromeos.h" |
| 128 #include "ash/sticky_keys/sticky_keys_controller.h" | 127 #include "ash/sticky_keys/sticky_keys_controller.h" |
| 129 #include "ash/system/chromeos/power/power_event_observer.h" | 128 #include "ash/system/chromeos/power/power_event_observer.h" |
| 130 #include "ash/system/chromeos/power/video_activity_notifier.h" | 129 #include "ash/system/chromeos/power/video_activity_notifier.h" |
| 131 #include "ash/touch/touch_transformer_controller.h" | 130 #include "ash/touch/touch_transformer_controller.h" |
| 132 #include "ash/virtual_keyboard_controller.h" | 131 #include "ash/virtual_keyboard_controller.h" |
| 133 #include "base/bind_helpers.h" | 132 #include "base/bind_helpers.h" |
| 134 #include "base/sys_info.h" | 133 #include "base/sys_info.h" |
| 135 #include "chromeos/audio/audio_a11y_controller.h" | 134 #include "chromeos/audio/audio_a11y_controller.h" |
| 136 #include "chromeos/chromeos_switches.h" | 135 #include "chromeos/chromeos_switches.h" |
| 137 #include "chromeos/dbus/dbus_thread_manager.h" | 136 #include "chromeos/dbus/dbus_thread_manager.h" |
| 138 #include "ui/chromeos/user_activity_power_manager_notifier.h" | 137 #include "ui/chromeos/user_activity_power_manager_notifier.h" |
| 138 #include "ui/display/manager/chromeos/display_change_observer.h" |
| 139 #include "ui/display/manager/chromeos/display_configurator.h" | 139 #include "ui/display/manager/chromeos/display_configurator.h" |
| 140 | 140 |
| 141 #if defined(USE_X11) | 141 #if defined(USE_X11) |
| 142 #include "ui/display/manager/chromeos/x11/native_display_delegate_x11.h" | 142 #include "ui/display/manager/chromeos/x11/native_display_delegate_x11.h" |
| 143 #endif | 143 #endif |
| 144 | 144 |
| 145 #if defined(USE_OZONE) | 145 #if defined(USE_OZONE) |
| 146 #include "ui/display/types/native_display_delegate.h" | 146 #include "ui/display/types/native_display_delegate.h" |
| 147 #include "ui/ozone/public/ozone_platform.h" | 147 #include "ui/ozone/public/ozone_platform.h" |
| 148 #endif | 148 #endif |
| (...skipping 466 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 615 | 615 |
| 616 // The DBusThreadManager must outlive this Shell. See the DCHECK in ~Shell. | 616 // The DBusThreadManager must outlive this Shell. See the DCHECK in ~Shell. |
| 617 chromeos::DBusThreadManager* dbus_thread_manager = | 617 chromeos::DBusThreadManager* dbus_thread_manager = |
| 618 chromeos::DBusThreadManager::Get(); | 618 chromeos::DBusThreadManager::Get(); |
| 619 projecting_observer_.reset( | 619 projecting_observer_.reset( |
| 620 new ProjectingObserver(dbus_thread_manager->GetPowerManagerClient())); | 620 new ProjectingObserver(dbus_thread_manager->GetPowerManagerClient())); |
| 621 display_configurator_->AddObserver(projecting_observer_.get()); | 621 display_configurator_->AddObserver(projecting_observer_.get()); |
| 622 wm_shell_->AddShellObserver(projecting_observer_.get()); | 622 wm_shell_->AddShellObserver(projecting_observer_.get()); |
| 623 | 623 |
| 624 if (!display_initialized && base::SysInfo::IsRunningOnChromeOS()) { | 624 if (!display_initialized && base::SysInfo::IsRunningOnChromeOS()) { |
| 625 display_change_observer_ = base::MakeUnique<DisplayChangeObserver>( | 625 display_change_observer_ = base::MakeUnique<display::DisplayChangeObserver>( |
| 626 display_configurator_.get(), display_manager_.get()); | 626 display_configurator_.get(), display_manager_.get()); |
| 627 | 627 |
| 628 shutdown_observer_ = | 628 shutdown_observer_ = |
| 629 base::MakeUnique<ShutdownObserver>(display_configurator_.get()); | 629 base::MakeUnique<ShutdownObserver>(display_configurator_.get()); |
| 630 | 630 |
| 631 // Register |display_change_observer_| first so that the rest of | 631 // Register |display_change_observer_| first so that the rest of |
| 632 // observer gets invoked after the root windows are configured. | 632 // observer gets invoked after the root windows are configured. |
| 633 display_configurator_->AddObserver(display_change_observer_.get()); | 633 display_configurator_->AddObserver(display_change_observer_.get()); |
| 634 display_error_observer_.reset(new DisplayErrorObserver()); | 634 display_error_observer_.reset(new DisplayErrorObserver()); |
| 635 display_configurator_->AddObserver(display_error_observer_.get()); | 635 display_configurator_->AddObserver(display_error_observer_.get()); |
| (...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 911 std::unique_ptr<ui::EventTargetIterator> Shell::GetChildIterator() const { | 911 std::unique_ptr<ui::EventTargetIterator> Shell::GetChildIterator() const { |
| 912 return std::unique_ptr<ui::EventTargetIterator>(); | 912 return std::unique_ptr<ui::EventTargetIterator>(); |
| 913 } | 913 } |
| 914 | 914 |
| 915 ui::EventTargeter* Shell::GetEventTargeter() { | 915 ui::EventTargeter* Shell::GetEventTargeter() { |
| 916 NOTREACHED(); | 916 NOTREACHED(); |
| 917 return nullptr; | 917 return nullptr; |
| 918 } | 918 } |
| 919 | 919 |
| 920 } // namespace ash | 920 } // namespace ash |
| OLD | NEW |