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

Unified Diff: ui/wm/core/accelerator_filter.cc

Issue 308023002: Add EF_IS_REPEAT flag to KeyEvent to handle repeated accelerators correctly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: use ui::EF_IS_REPEAT in test instead Created 6 years, 6 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
« no previous file with comments | « ui/wm/core/accelerator_delegate.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/wm/core/accelerator_filter.cc
diff --git a/ui/wm/core/accelerator_filter.cc b/ui/wm/core/accelerator_filter.cc
index 706cb2e5065abad119968c95c7d0210d16a6ae56..51c6106d91e3b6a0745bb8ba11445874505406ab 100644
--- a/ui/wm/core/accelerator_filter.cc
+++ b/ui/wm/core/accelerator_filter.cc
@@ -57,8 +57,6 @@ void AcceleratorFilter::OnKeyEvent(ui::KeyEvent* event) {
ui::Accelerator accelerator = CreateAcceleratorFromKeyEvent(*event);
- delegate_->PreProcessAccelerator(accelerator);
-
AcceleratorDelegate::KeyType key_type =
IsSystemKey(event->key_code()) ? AcceleratorDelegate::KEY_TYPE_SYSTEM
: AcceleratorDelegate::KEY_TYPE_OTHER;
@@ -75,6 +73,7 @@ ui::Accelerator CreateAcceleratorFromKeyEvent(const ui::KeyEvent& key_event) {
key_event.flags() & kModifierFlagMask);
if (key_event.type() == ui::ET_KEY_RELEASED)
accelerator.set_type(ui::ET_KEY_RELEASED);
+ accelerator.set_is_repeat(key_event.IsRepeat());
return accelerator;
}
« no previous file with comments | « ui/wm/core/accelerator_delegate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698