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

Unified Diff: ui/events/event_utils.cc

Issue 2193153002: MacViews: Send Mac scrollWheel NSEvents as ui::ET_SCROLL (ui::ScrollEvent). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@20160728-MacViews-ScrollLayers
Patch Set: Support Widget MouseWheelEvent conversion Created 4 years, 3 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_utils.cc
diff --git a/ui/events/event_utils.cc b/ui/events/event_utils.cc
index 3095ad022d327cc22a6e04a918948a0b5ad3aaed..389edcadad60e01f232fa1b75d0a66658afe0483 100644
--- a/ui/events/event_utils.cc
+++ b/ui/events/event_utils.cc
@@ -110,6 +110,10 @@ void ComputeEventLatencyOS(const base::NativeEvent& native_event) {
EventType type = EventTypeFromNative(native_event);
switch (type) {
+#if defined(OS_MACOSX)
+ // On Mac, ET_SCROLL and ET_MOUSEWHEEL represent the same class of events.
+ case ET_SCROLL:
+#endif
case ET_MOUSEWHEEL:
UMA_HISTOGRAM_CUSTOM_COUNTS("Event.Latency.OS.MOUSE_WHEEL",
delta.InMicroseconds(), 1, 1000000, 50);

Powered by Google App Engine
This is Rietveld 408576698