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

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

Issue 2923723002: Avoid toggling app list if interrupted by mouse (Closed)
Patch Set: Rebase and refactor is_interrupted_by_mouse_event() to interrupted_by_mouse_event() Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/wm/core/accelerator_filter.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 03ea898737df0f39963032d3863a04f738ecb66c..21f10d5bf05ab67b807da977ad3d66f9f95fd32e 100644
--- a/ui/wm/core/accelerator_filter.cc
+++ b/ui/wm/core/accelerator_filter.cc
@@ -46,4 +46,11 @@ void AcceleratorFilter::OnKeyEvent(ui::KeyEvent* event) {
event->StopPropagation();
}
+void AcceleratorFilter::OnMouseEvent(ui::MouseEvent* event) {
+ if (event->type() == ui::ET_MOUSE_PRESSED ||
+ event->type() == ui::ET_MOUSE_RELEASED) {
+ accelerator_history_->InterruptCurrentAccelerator();
+ }
+}
+
} // namespace wm
« no previous file with comments | « ui/wm/core/accelerator_filter.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698