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

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

Issue 2729363002: chromeos: Move files in //ash/common to //ash, part 3 (Closed)
Patch Set: Created 3 years, 9 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/common/session/session_state_delegate.h"
8 #include "ash/common/wm_shell.h"
9 #include "ash/common/wm_window.h"
10 #include "ash/metrics/task_switch_source.h" 7 #include "ash/metrics/task_switch_source.h"
11 #include "ash/public/cpp/shell_window_ids.h" 8 #include "ash/public/cpp/shell_window_ids.h"
9 #include "ash/session/session_state_delegate.h"
12 #include "ash/wm/mru_window_tracker.h" 10 #include "ash/wm/mru_window_tracker.h"
13 #include "ash/wm/window_cycle_event_filter.h" 11 #include "ash/wm/window_cycle_event_filter.h"
14 #include "ash/wm/window_cycle_list.h" 12 #include "ash/wm/window_cycle_list.h"
15 #include "ash/wm/window_state.h" 13 #include "ash/wm/window_state.h"
14 #include "ash/wm_shell.h"
15 #include "ash/wm_window.h"
16 #include "base/metrics/histogram_macros.h" 16 #include "base/metrics/histogram_macros.h"
17 17
18 namespace ash { 18 namespace ash {
19 19
20 namespace { 20 namespace {
21 21
22 // Returns the most recently active window from the |window_list| or nullptr 22 // Returns the most recently active window from the |window_list| or nullptr
23 // if the list is empty. 23 // if the list is empty.
24 WmWindow* GetActiveWindow(const MruWindowTracker::WindowList& window_list) { 24 WmWindow* GetActiveWindow(const MruWindowTracker::WindowList& window_list) {
25 return window_list.empty() ? nullptr : window_list[0]; 25 return window_list.empty() ? nullptr : window_list[0];
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 117
118 if (active_window_after_window_cycle != nullptr && 118 if (active_window_after_window_cycle != nullptr &&
119 active_window_before_window_cycle_ != active_window_after_window_cycle) { 119 active_window_before_window_cycle_ != active_window_after_window_cycle) {
120 WmShell::Get()->RecordTaskSwitchMetric( 120 WmShell::Get()->RecordTaskSwitchMetric(
121 TaskSwitchSource::WINDOW_CYCLE_CONTROLLER); 121 TaskSwitchSource::WINDOW_CYCLE_CONTROLLER);
122 } 122 }
123 active_window_before_window_cycle_ = nullptr; 123 active_window_before_window_cycle_ = nullptr;
124 } 124 }
125 125
126 } // namespace ash 126 } // 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