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

Unified Diff: ui/views/win/hwnd_message_handler.cc

Issue 1148143002: Revert of Fix a crash when views::HWNDMessageHandler::HandleTouchMessage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/win/hwnd_message_handler.cc
diff --git a/ui/views/win/hwnd_message_handler.cc b/ui/views/win/hwnd_message_handler.cc
index 7dea7ae60f504d3e189e3d74072deb5cafbe326e..cb34bbe7999d9a4412b27e04a1656cc2265a5d2d 100644
--- a/ui/views/win/hwnd_message_handler.cc
+++ b/ui/views/win/hwnd_message_handler.cc
@@ -2350,11 +2350,6 @@
ScreenToClient(hwnd(), &point);
- // We set a check to assert that we do not receive any touch events from
- // user's palm.
- bool touch_event_from_palm = (input[i].dwFlags & TOUCHEVENTF_PALM) != 0;
- CHECK(!touch_event_from_palm) << "There are touch events from user's palm";
-
// TOUCHEVENTF_DOWN cannot be combined with TOUCHEVENTF_MOVE or
// TOUCHEVENTF_UP, but TOUCHEVENTF_MOVE and TOUCHEVENTF_UP can be combined
// in one input.
@@ -2390,19 +2385,18 @@
}
TouchPoint& touch_point = touch_id_list_[touch_id];
+ int flags = ui::GetModifiersFromKeyState();
+
+ // The dwTime of every input in the WM_TOUCH message doesn't necessarily
+ // relate to the system time at all, so use base::TimeTicks::Now() for
+ // touchevent time.
+ base::TimeDelta now = ui::EventTimeForNow();
// We set a check to assert that we do not have missing touch presses in
// every message.
bool has_missing_touch_press = touch_event_type != ui::ET_TOUCH_PRESSED &&
touch_point.in_touch_list == InTouchList::NotPresent;
CHECK(!has_missing_touch_press) << "There are missing touch presses";
-
- int flags = ui::GetModifiersFromKeyState();
-
- // The dwTime of every input in the WM_TOUCH message doesn't necessarily
- // relate to the system time at all, so use base::TimeTicks::Now() for
- // touchevent time.
- base::TimeDelta now = ui::EventTimeForNow();
ui::TouchEvent event(touch_event_type, point_location, touch_id, now);
event.set_flags(flags);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698