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 | 9 |
10 #include "ash/accelerators/accelerator_controller.h" | 10 #include "ash/accelerators/accelerator_controller.h" |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 #include "ash/wm/power_button_controller.h" | 66 #include "ash/wm/power_button_controller.h" |
67 #include "ash/wm/resize_shadow_controller.h" | 67 #include "ash/wm/resize_shadow_controller.h" |
68 #include "ash/wm/root_window_layout_manager.h" | 68 #include "ash/wm/root_window_layout_manager.h" |
69 #include "ash/wm/screen_dimmer.h" | 69 #include "ash/wm/screen_dimmer.h" |
70 #include "ash/wm/system_gesture_event_filter.h" | 70 #include "ash/wm/system_gesture_event_filter.h" |
71 #include "ash/wm/system_modal_container_event_filter.h" | 71 #include "ash/wm/system_modal_container_event_filter.h" |
72 #include "ash/wm/system_modal_container_layout_manager.h" | 72 #include "ash/wm/system_modal_container_layout_manager.h" |
73 #include "ash/wm/toplevel_window_event_handler.h" | 73 #include "ash/wm/toplevel_window_event_handler.h" |
74 #include "ash/wm/video_detector.h" | 74 #include "ash/wm/video_detector.h" |
75 #include "ash/wm/window_animations.h" | 75 #include "ash/wm/window_animations.h" |
| 76 #include "ash/wm/window_cycle_controller.h" |
76 #include "ash/wm/window_positioner.h" | 77 #include "ash/wm/window_positioner.h" |
77 #include "ash/wm/window_properties.h" | 78 #include "ash/wm/window_properties.h" |
78 #include "ash/wm/window_util.h" | 79 #include "ash/wm/window_util.h" |
79 #include "ash/wm/workspace_controller.h" | 80 #include "ash/wm/workspace_controller.h" |
80 #include "base/bind.h" | 81 #include "base/bind.h" |
81 #include "base/debug/trace_event.h" | 82 #include "base/debug/trace_event.h" |
82 #include "ui/aura/client/aura_constants.h" | 83 #include "ui/aura/client/aura_constants.h" |
83 #include "ui/aura/env.h" | 84 #include "ui/aura/env.h" |
84 #include "ui/aura/layout_manager.h" | 85 #include "ui/aura/layout_manager.h" |
85 #include "ui/aura/window.h" | 86 #include "ui/aura/window.h" |
(...skipping 619 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
705 // deleted because it's observing video activity through | 706 // deleted because it's observing video activity through |
706 // VideoDetectorObserver interface. | 707 // VideoDetectorObserver interface. |
707 video_activity_notifier_.reset(); | 708 video_activity_notifier_.reset(); |
708 #endif // defined(OS_CHROMEOS) | 709 #endif // defined(OS_CHROMEOS) |
709 video_detector_.reset(); | 710 video_detector_.reset(); |
710 high_contrast_controller_.reset(); | 711 high_contrast_controller_.reset(); |
711 | 712 |
712 shadow_controller_.reset(); | 713 shadow_controller_.reset(); |
713 resize_shadow_controller_.reset(); | 714 resize_shadow_controller_.reset(); |
714 | 715 |
| 716 window_cycle_controller_.reset(); |
715 window_selector_controller_.reset(); | 717 window_selector_controller_.reset(); |
716 mru_window_tracker_.reset(); | 718 mru_window_tracker_.reset(); |
717 | 719 |
718 // |shelf_window_watcher_| has a weak pointer to |shelf_Model_| | 720 // |shelf_window_watcher_| has a weak pointer to |shelf_Model_| |
719 // and has window observers. | 721 // and has window observers. |
720 shelf_window_watcher_.reset(); | 722 shelf_window_watcher_.reset(); |
721 | 723 |
722 // Destroy all child windows including widgets. | 724 // Destroy all child windows including widgets. |
723 display_controller_->CloseChildWindows(); | 725 display_controller_->CloseChildWindows(); |
724 display_controller_->CloseNonDesktopDisplay(); | 726 display_controller_->CloseNonDesktopDisplay(); |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
939 mru_window_tracker_.reset(new MruWindowTracker(activation_client_)); | 941 mru_window_tracker_.reset(new MruWindowTracker(activation_client_)); |
940 | 942 |
941 partial_magnification_controller_.reset( | 943 partial_magnification_controller_.reset( |
942 new PartialMagnificationController()); | 944 new PartialMagnificationController()); |
943 | 945 |
944 autoclick_controller_.reset(AutoclickController::CreateInstance()); | 946 autoclick_controller_.reset(AutoclickController::CreateInstance()); |
945 | 947 |
946 high_contrast_controller_.reset(new HighContrastController); | 948 high_contrast_controller_.reset(new HighContrastController); |
947 video_detector_.reset(new VideoDetector); | 949 video_detector_.reset(new VideoDetector); |
948 window_selector_controller_.reset(new WindowSelectorController()); | 950 window_selector_controller_.reset(new WindowSelectorController()); |
| 951 window_cycle_controller_.reset(new WindowCycleController()); |
949 | 952 |
950 tooltip_controller_.reset( | 953 tooltip_controller_.reset( |
951 new views::corewm::TooltipController( | 954 new views::corewm::TooltipController( |
952 scoped_ptr<views::corewm::Tooltip>( | 955 scoped_ptr<views::corewm::Tooltip>( |
953 new views::corewm::TooltipAura(gfx::SCREEN_TYPE_ALTERNATE)))); | 956 new views::corewm::TooltipAura(gfx::SCREEN_TYPE_ALTERNATE)))); |
954 AddPreTargetHandler(tooltip_controller_.get()); | 957 AddPreTargetHandler(tooltip_controller_.get()); |
955 | 958 |
956 event_client_.reset(new EventClientImpl); | 959 event_client_.reset(new EventClientImpl); |
957 | 960 |
958 // This controller needs to be set before SetupManagedWindowMode. | 961 // This controller needs to be set before SetupManagedWindowMode. |
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1116 //////////////////////////////////////////////////////////////////////////////// | 1119 //////////////////////////////////////////////////////////////////////////////// |
1117 // Shell, aura::client::ActivationChangeObserver implementation: | 1120 // Shell, aura::client::ActivationChangeObserver implementation: |
1118 | 1121 |
1119 void Shell::OnWindowActivated(aura::Window* gained_active, | 1122 void Shell::OnWindowActivated(aura::Window* gained_active, |
1120 aura::Window* lost_active) { | 1123 aura::Window* lost_active) { |
1121 if (gained_active) | 1124 if (gained_active) |
1122 target_root_window_ = gained_active->GetRootWindow(); | 1125 target_root_window_ = gained_active->GetRootWindow(); |
1123 } | 1126 } |
1124 | 1127 |
1125 } // namespace ash | 1128 } // namespace ash |
OLD | NEW |