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

Unified Diff: ui/events/event.cc

Issue 400213002: Refcount touch tracking ids to prevent freeing them too early. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix non-linux platforms. Created 6 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
Index: ui/events/event.cc
diff --git a/ui/events/event.cc b/ui/events/event.cc
index df38f38365ace7a3d8adbd89ea72bf7d493385ae..5f434ac5590ee9821ceb974fd3eeea16e18bfe16 100644
--- a/ui/events/event.cc
+++ b/ui/events/event.cc
@@ -448,6 +448,9 @@ TouchEvent::TouchEvent(const base::NativeEvent& native_event)
1);
latency()->AddLatencyNumber(INPUT_EVENT_LATENCY_UI_COMPONENT, 0, 0);
+
+ if (type() == ET_TOUCH_PRESSED)
+ IncrementTouchIdRefCount(native_event);
}
TouchEvent::TouchEvent(EventType type,
« no previous file with comments | « ui/events/cocoa/events_mac.mm ('k') | ui/events/event_utils.h » ('j') | ui/events/x/events_x.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698