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

Unified Diff: chrome/browser/ui/views/frame/browser_view.cc

Issue 2074643003: MacViews: Views accelerators table should match the Cocoa one. (Closed) Base URL: ssh://bitbucket.browser.yandex-team.ru/chromium/src.git@master
Patch Set: Updated accelerator_table.cc, removed non-Cocoa shortcuts, added global_keyboard_shortcuts_mac.mm h… Created 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/frame/browser_view.cc
diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc
index dbaf157c6e078beaa61153346d4d98c12344512c..71fc86a771230f17139da5028a1093067da76ce2 100644
--- a/chrome/browser/ui/views/frame/browser_view.cc
+++ b/chrome/browser/ui/views/frame/browser_view.cc
@@ -72,6 +72,7 @@
#include "chrome/browser/ui/views/find_bar_host.h"
#include "chrome/browser/ui/views/frame/browser_view_layout.h"
#include "chrome/browser/ui/views/frame/browser_view_layout_delegate.h"
+#include "chrome/browser/ui/views/frame/browser_view_platform.h"
#include "chrome/browser/ui/views/frame/contents_layout_manager.h"
#include "chrome/browser/ui/views/frame/immersive_mode_controller.h"
#include "chrome/browser/ui/views/frame/top_container_view.h"
@@ -1417,6 +1418,9 @@ bool BrowserView::PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event,
}
#endif // defined(OS_CHROMEOS)
+ if (BrowserViewPlatform::PreHandleKeyboardEvent(event, browser()))
tapted 2016/10/17 07:02:47 I'm not an owner here, but based on the surroundin
themblsha 2016/10/20 16:41:05 Thanks! Moved the code there.
+ return true;
+
chrome::BrowserCommandController* controller = browser_->command_controller();
// Here we need to retrieve the command id (if any) associated to the
@@ -1454,6 +1458,9 @@ bool BrowserView::PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event,
}
void BrowserView::HandleKeyboardEvent(const NativeWebKeyboardEvent& event) {
+ if (BrowserViewPlatform::HandleKeyboardEvent(event, browser()))
+ return;
+
unhandled_keyboard_event_handler_.HandleKeyboardEvent(event,
tapted 2016/10/17 07:02:47 There is already a mac-specific UnhandledKeyboardE
themblsha 2016/10/20 16:41:05 Tried to do that: https://gist.github.com/mblsha/d
GetFocusManager());
}

Powered by Google App Engine
This is Rietveld 408576698