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

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

Issue 2169533002: mash: Migrate shelf app list button to wm common types (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 5 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
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_controller.h" 7 #include "ash/accelerators/accelerator_controller.h"
8 #include "ash/common/wm/window_state.h" 8 #include "ash/common/wm/window_state.h"
9 #include "ash/common/wm_shell.h"
9 #include "ash/shell.h" 10 #include "ash/shell.h"
10 #include "ash/wm/window_state_aura.h" 11 #include "ash/wm/window_state_aura.h"
11 #include "ui/base/accelerators/accelerator.h" 12 #include "ui/base/accelerators/accelerator.h"
12 #include "ui/events/event.h" 13 #include "ui/events/event.h"
13 #include "ui/wm/core/window_util.h" 14 #include "ui/wm/core/window_util.h"
14 15
15 namespace ash { 16 namespace ash {
16 17
17 namespace { 18 namespace {
18 19
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 // send key events to a web content first, then will process keys 103 // send key events to a web content first, then will process keys
103 // if the web content didn't consume them. 104 // if the web content didn't consume them.
104 return false; 105 return false;
105 } 106 }
106 107
107 // Handle preferred accelerators (such as ALT-TAB) before sending 108 // Handle preferred accelerators (such as ALT-TAB) before sending
108 // to the target. 109 // to the target.
109 if (shell->accelerator_controller()->IsPreferred(accelerator)) 110 if (shell->accelerator_controller()->IsPreferred(accelerator))
110 return true; 111 return true;
111 112
112 return shell->GetAppListTargetVisibility(); 113 return WmShell::Get()->GetAppListTargetVisibility();
113 } 114 }
114 115
115 } // namespace ash 116 } // namespace ash
OLDNEW
« no previous file with comments | « ash/accelerators/accelerator_controller_unittest.cc ('k') | ash/accelerators/accelerator_filter_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698