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

Unified Diff: ui/aura/root_window.cc

Issue 160563002: Aura: don't synthesize mouse moves while holding pointer. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added check for synthetic event Created 6 years, 10 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 | « no previous file | ui/aura/root_window_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/aura/root_window.cc
diff --git a/ui/aura/root_window.cc b/ui/aura/root_window.cc
index 04ced914c62ad451637a4728e17e2ef8a20a384d..8733816bc5f57a1e0472ec7f7f5dc46ae3a22f34 100644
--- a/ui/aura/root_window.cc
+++ b/ui/aura/root_window.cc
@@ -791,6 +791,10 @@ void RootWindow::PreDispatchMouseEvent(Window* target,
if (IsEventCandidateForHold(*event) && !dispatching_held_event_) {
if (move_hold_count_) {
+ if (!(event->flags() & ui::EF_IS_SYNTHESIZED) &&
+ event->type() != ui::ET_MOUSE_CAPTURE_CHANGED) {
+ SetLastMouseLocation(window(), event->root_location());
+ }
held_move_event_.reset(new ui::MouseEvent(*event, target, window()));
event->SetHandled();
return;
« no previous file with comments | « no previous file | ui/aura/root_window_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698