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

Side by Side Diff: ash/accelerators/accelerator_delegate.cc

Issue 2901413005: [mus+ash] Removes WmWindow from ash/accelerators (Closed)
Patch Set: [mus+ash] Removes WmWindow from ash/accelerators (rebased) Created 3 years, 7 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/accelerators/accelerator_controller.cc ('k') | ash/accelerators/accelerator_router.h » ('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/accelerators/accelerator_delegate.h" 5 #include "ash/accelerators/accelerator_delegate.h"
6 6
7 #include "ash/accelerators/accelerator_router.h" 7 #include "ash/accelerators/accelerator_router.h"
8 #include "ash/wm_window.h"
9 #include "ui/aura/window.h" 8 #include "ui/aura/window.h"
10 #include "ui/events/event.h" 9 #include "ui/events/event.h"
11 10
12 namespace ash { 11 namespace ash {
13 12
14 AcceleratorDelegate::AcceleratorDelegate() : router_(new AcceleratorRouter) {} 13 AcceleratorDelegate::AcceleratorDelegate() : router_(new AcceleratorRouter) {}
15 14
16 AcceleratorDelegate::~AcceleratorDelegate() {} 15 AcceleratorDelegate::~AcceleratorDelegate() {}
17 16
18 bool AcceleratorDelegate::ProcessAccelerator( 17 bool AcceleratorDelegate::ProcessAccelerator(
19 const ui::KeyEvent& key_event, 18 const ui::KeyEvent& key_event,
20 const ui::Accelerator& accelerator) { 19 const ui::Accelerator& accelerator) {
21 return router_->ProcessAccelerator( 20 return router_->ProcessAccelerator(
22 WmWindow::Get(static_cast<aura::Window*>(key_event.target())), key_event, 21 static_cast<aura::Window*>(key_event.target()), key_event, accelerator);
23 accelerator);
24 } 22 }
25 23
26 } // namespace ash 24 } // namespace ash
OLDNEW
« no previous file with comments | « ash/accelerators/accelerator_controller.cc ('k') | ash/accelerators/accelerator_router.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698