Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(217)

Side by Side Diff: ash/shell.cc

Issue 2585633004: ozone: Allow ozone evdev/kvm features to be enabled without running on ChromeOS. (Closed)
Patch Set: only add //chromeos to deps if is_chromeos Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 #include "ash/sticky_keys/sticky_keys_controller.h" 127 #include "ash/sticky_keys/sticky_keys_controller.h"
128 #include "ash/system/chromeos/power/power_event_observer.h" 128 #include "ash/system/chromeos/power/power_event_observer.h"
129 #include "ash/system/chromeos/power/video_activity_notifier.h" 129 #include "ash/system/chromeos/power/video_activity_notifier.h"
130 #include "ash/touch/touch_transformer_controller.h" 130 #include "ash/touch/touch_transformer_controller.h"
131 #include "ash/virtual_keyboard_controller.h" 131 #include "ash/virtual_keyboard_controller.h"
132 #include "base/bind_helpers.h" 132 #include "base/bind_helpers.h"
133 #include "base/sys_info.h" 133 #include "base/sys_info.h"
134 #include "chromeos/audio/audio_a11y_controller.h" 134 #include "chromeos/audio/audio_a11y_controller.h"
135 #include "chromeos/chromeos_switches.h" 135 #include "chromeos/chromeos_switches.h"
136 #include "chromeos/dbus/dbus_thread_manager.h" 136 #include "chromeos/dbus/dbus_thread_manager.h"
137 #include "chromeos/system/devicemode.h"
137 #include "ui/chromeos/user_activity_power_manager_notifier.h" 138 #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_change_observer.h"
139 #include "ui/display/manager/chromeos/display_configurator.h" 140 #include "ui/display/manager/chromeos/display_configurator.h"
140 141
141 #if defined(USE_X11) 142 #if defined(USE_X11)
142 #include "ui/display/manager/chromeos/x11/native_display_delegate_x11.h" 143 #include "ui/display/manager/chromeos/x11/native_display_delegate_x11.h"
143 #endif 144 #endif
144 145
145 #if defined(USE_OZONE) 146 #if defined(USE_OZONE)
146 #include "ui/display/types/native_display_delegate.h" 147 #include "ui/display/types/native_display_delegate.h"
(...skipping 462 matching lines...) Expand 10 before | Expand all | Expand 10 after
609 #endif 610 #endif
610 611
611 // The DBusThreadManager must outlive this Shell. See the DCHECK in ~Shell. 612 // The DBusThreadManager must outlive this Shell. See the DCHECK in ~Shell.
612 chromeos::DBusThreadManager* dbus_thread_manager = 613 chromeos::DBusThreadManager* dbus_thread_manager =
613 chromeos::DBusThreadManager::Get(); 614 chromeos::DBusThreadManager::Get();
614 projecting_observer_.reset( 615 projecting_observer_.reset(
615 new ProjectingObserver(dbus_thread_manager->GetPowerManagerClient())); 616 new ProjectingObserver(dbus_thread_manager->GetPowerManagerClient()));
616 display_configurator_->AddObserver(projecting_observer_.get()); 617 display_configurator_->AddObserver(projecting_observer_.get());
617 wm_shell_->AddShellObserver(projecting_observer_.get()); 618 wm_shell_->AddShellObserver(projecting_observer_.get());
618 619
619 if (!display_initialized && base::SysInfo::IsRunningOnChromeOS()) { 620 if (!display_initialized && chromeos::IsRunningAsSystemCompositor()) {
620 display_change_observer_ = base::MakeUnique<display::DisplayChangeObserver>( 621 display_change_observer_ = base::MakeUnique<display::DisplayChangeObserver>(
621 display_configurator_.get(), display_manager_.get()); 622 display_configurator_.get(), display_manager_.get());
622 623
623 shutdown_observer_ = 624 shutdown_observer_ =
624 base::MakeUnique<ShutdownObserver>(display_configurator_.get()); 625 base::MakeUnique<ShutdownObserver>(display_configurator_.get());
625 626
626 // Register |display_change_observer_| first so that the rest of 627 // Register |display_change_observer_| first so that the rest of
627 // observer gets invoked after the root windows are configured. 628 // observer gets invoked after the root windows are configured.
628 display_configurator_->AddObserver(display_change_observer_.get()); 629 display_configurator_->AddObserver(display_change_observer_.get());
629 display_error_observer_.reset(new DisplayErrorObserver()); 630 display_error_observer_.reset(new DisplayErrorObserver());
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
908 std::unique_ptr<ui::EventTargetIterator> Shell::GetChildIterator() const { 909 std::unique_ptr<ui::EventTargetIterator> Shell::GetChildIterator() const {
909 return std::unique_ptr<ui::EventTargetIterator>(); 910 return std::unique_ptr<ui::EventTargetIterator>();
910 } 911 }
911 912
912 ui::EventTargeter* Shell::GetEventTargeter() { 913 ui::EventTargeter* Shell::GetEventTargeter() {
913 NOTREACHED(); 914 NOTREACHED();
914 return nullptr; 915 return nullptr;
915 } 916 }
916 917
917 } // namespace ash 918 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698