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

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

Issue 621133002: replace OVERRIDE and FINAL with override and final in ash/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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_unittest.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/session/session_state_delegate.h" 7 #include "ash/session/session_state_delegate.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "ash/wm/mru_window_tracker.h" 9 #include "ash/wm/mru_window_tracker.h"
10 #include "ash/wm/window_cycle_list.h" 10 #include "ash/wm/window_cycle_list.h"
11 #include "base/metrics/histogram.h" 11 #include "base/metrics/histogram.h"
12 #include "ui/events/event.h" 12 #include "ui/events/event.h"
13 #include "ui/events/event_handler.h" 13 #include "ui/events/event_handler.h"
14 14
15 namespace ash { 15 namespace ash {
16 16
17 namespace { 17 namespace {
18 18
19 // Filter to watch for the termination of a keyboard gesture to cycle through 19 // Filter to watch for the termination of a keyboard gesture to cycle through
20 // multiple windows. 20 // multiple windows.
21 class WindowCycleEventFilter : public ui::EventHandler { 21 class WindowCycleEventFilter : public ui::EventHandler {
22 public: 22 public:
23 WindowCycleEventFilter(); 23 WindowCycleEventFilter();
24 virtual ~WindowCycleEventFilter(); 24 virtual ~WindowCycleEventFilter();
25 25
26 // Overridden from ui::EventHandler: 26 // Overridden from ui::EventHandler:
27 virtual void OnKeyEvent(ui::KeyEvent* event) OVERRIDE; 27 virtual void OnKeyEvent(ui::KeyEvent* event) override;
28 28
29 private: 29 private:
30 DISALLOW_COPY_AND_ASSIGN(WindowCycleEventFilter); 30 DISALLOW_COPY_AND_ASSIGN(WindowCycleEventFilter);
31 }; 31 };
32 32
33 WindowCycleEventFilter::WindowCycleEventFilter() { 33 WindowCycleEventFilter::WindowCycleEventFilter() {
34 Shell::GetInstance()->AddPreTargetHandler(this); 34 Shell::GetInstance()->AddPreTargetHandler(this);
35 } 35 }
36 36
37 WindowCycleEventFilter::~WindowCycleEventFilter() { 37 WindowCycleEventFilter::~WindowCycleEventFilter() {
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 94
95 void WindowCycleController::StopCycling() { 95 void WindowCycleController::StopCycling() {
96 window_cycle_list_.reset(); 96 window_cycle_list_.reset();
97 // Remove our key event filter. 97 // Remove our key event filter.
98 event_handler_.reset(); 98 event_handler_.reset();
99 UMA_HISTOGRAM_MEDIUM_TIMES("Ash.WindowCycleController.CycleTime", 99 UMA_HISTOGRAM_MEDIUM_TIMES("Ash.WindowCycleController.CycleTime",
100 base::Time::Now() - cycle_start_time_); 100 base::Time::Now() - cycle_start_time_);
101 } 101 }
102 102
103 } // namespace ash 103 } // namespace ash
OLDNEW
« no previous file with comments | « ash/wm/window_animations_unittest.cc ('k') | ash/wm/window_cycle_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698