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

Side by Side Diff: ash/wm/window_cycle_controller.cc

Issue 2907853002: [mus+ash] Removes WmWindow from ash/shelf and ash/shell (Closed)
Patch Set: [mus+ash] Removes WmWindow from ash/shelf and ash/shell (removed some more wm_window.h) Created 3 years, 6 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
« no previous file with comments | « ash/wm/window_animations.cc ('k') | ash/wm/window_cycle_controller_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/wm/window_cycle_controller.h" 5 #include "ash/wm/window_cycle_controller.h"
6 6
7 #include "ash/metrics/task_switch_source.h" 7 #include "ash/metrics/task_switch_source.h"
8 #include "ash/public/cpp/shell_window_ids.h" 8 #include "ash/public/cpp/shell_window_ids.h"
9 #include "ash/session/session_controller.h" 9 #include "ash/session/session_controller.h"
10 #include "ash/shell.h" 10 #include "ash/shell.h"
11 #include "ash/shell_port.h" 11 #include "ash/shell_port.h"
12 #include "ash/wm/mru_window_tracker.h" 12 #include "ash/wm/mru_window_tracker.h"
13 #include "ash/wm/screen_pinning_controller.h" 13 #include "ash/wm/screen_pinning_controller.h"
14 #include "ash/wm/window_cycle_event_filter.h" 14 #include "ash/wm/window_cycle_event_filter.h"
15 #include "ash/wm/window_cycle_list.h" 15 #include "ash/wm/window_cycle_list.h"
16 #include "ash/wm/window_state.h" 16 #include "ash/wm/window_state.h"
17 #include "ash/wm_window.h"
18 #include "base/metrics/histogram_macros.h" 17 #include "base/metrics/histogram_macros.h"
19 18
20 namespace ash { 19 namespace ash {
21 20
22 namespace { 21 namespace {
23 22
24 // Returns the most recently active window from the |window_list| or nullptr 23 // Returns the most recently active window from the |window_list| or nullptr
25 // if the list is empty. 24 // if the list is empty.
26 aura::Window* GetActiveWindow(const WindowCycleList::WindowList& window_list) { 25 aura::Window* GetActiveWindow(const WindowCycleList::WindowList& window_list) {
27 return window_list.empty() ? nullptr : window_list[0]; 26 return window_list.empty() ? nullptr : window_list[0];
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 118
120 if (active_window_after_window_cycle != nullptr && 119 if (active_window_after_window_cycle != nullptr &&
121 active_window_before_window_cycle_ != active_window_after_window_cycle) { 120 active_window_before_window_cycle_ != active_window_after_window_cycle) {
122 ShellPort::Get()->RecordTaskSwitchMetric( 121 ShellPort::Get()->RecordTaskSwitchMetric(
123 TaskSwitchSource::WINDOW_CYCLE_CONTROLLER); 122 TaskSwitchSource::WINDOW_CYCLE_CONTROLLER);
124 } 123 }
125 active_window_before_window_cycle_ = nullptr; 124 active_window_before_window_cycle_ = nullptr;
126 } 125 }
127 126
128 } // namespace ash 127 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/window_animations.cc ('k') | ash/wm/window_cycle_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698