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

Side by Side Diff: chrome/browser/ui/views/accelerator_utils_views.cc

Issue 246633004: Remove non USE_AURA code from views files. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Just revert changes to ui/app_list/. Created 6 years, 8 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "ui/base/accelerators/accelerator.h"
6 #include "chrome/browser/profiles/profile.h"
7 #include "chrome/browser/ui/browser.h"
8 #include "chrome/browser/ui/browser_finder.h"
9 #include "chrome/browser/ui/views/frame/browser_view.h"
10
11 namespace chrome {
12
13 #if !defined(USE_AURA)
14
15 bool IsChromeAccelerator(const ui::Accelerator& accelerator, Profile* profile) {
16 Browser* browser = chrome::FindLastActiveWithProfile(
17 profile, chrome::HOST_DESKTOP_TYPE_NATIVE);
18 if (!browser)
19 return false;
20 BrowserView* browser_view = BrowserView::GetBrowserViewForNativeWindow(
21 browser->window()->GetNativeWindow());
22 return browser_view->IsAcceleratorRegistered(accelerator);
23 }
24
25 #endif // !USE_AURA
26
27 } // namespace chrome
OLDNEW
« no previous file with comments | « chrome/browser/first_run/try_chrome_dialog_view.cc ('k') | chrome/browser/ui/views/autofill/autofill_popup_base_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698