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

Side by Side Diff: third_party/WebKit/Source/web/WebInputEventConversion.cpp

Issue 1812653002: Scale the deltaX/deltaY on the mouse wheel events to be consistent with the compositor implementati… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove unnecessary arguments from call Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « third_party/WebKit/LayoutTests/fast/events/scroll-in-scaled-page-with-overflow-hidden.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 ASSERT_NOT_REACHED(); 146 ASSERT_NOT_REACHED();
147 } 147 }
148 } 148 }
149 149
150 // PlatformWheelEventBuilder -------------------------------------------------- 150 // PlatformWheelEventBuilder --------------------------------------------------
151 151
152 PlatformWheelEventBuilder::PlatformWheelEventBuilder(Widget* widget, const WebMo useWheelEvent& e) 152 PlatformWheelEventBuilder::PlatformWheelEventBuilder(Widget* widget, const WebMo useWheelEvent& e)
153 { 153 {
154 m_position = widget->convertFromRootFrame(flooredIntPoint(convertHitPointToR ootFrame(widget, FloatPoint(e.x, e.y)))); 154 m_position = widget->convertFromRootFrame(flooredIntPoint(convertHitPointToR ootFrame(widget, FloatPoint(e.x, e.y))));
155 m_globalPosition = IntPoint(e.globalX, e.globalY); 155 m_globalPosition = IntPoint(e.globalX, e.globalY);
156 m_deltaX = e.deltaX; 156 m_deltaX = scaleDeltaToWindow(widget, e.deltaX);
157 m_deltaY = e.deltaY; 157 m_deltaY = scaleDeltaToWindow(widget, e.deltaY);
158 m_wheelTicksX = e.wheelTicksX; 158 m_wheelTicksX = e.wheelTicksX;
159 m_wheelTicksY = e.wheelTicksY; 159 m_wheelTicksY = e.wheelTicksY;
160 m_granularity = e.scrollByPage ? 160 m_granularity = e.scrollByPage ?
161 ScrollByPageWheelEvent : ScrollByPixelWheelEvent; 161 ScrollByPageWheelEvent : ScrollByPixelWheelEvent;
162 162
163 m_type = PlatformEvent::Wheel; 163 m_type = PlatformEvent::Wheel;
164 164
165 m_timestamp = e.timeStampSeconds; 165 m_timestamp = e.timeStampSeconds;
166 m_modifiers = e.modifiers; 166 m_modifiers = e.modifiers;
167 167
(...skipping 577 matching lines...) Expand 10 before | Expand all | Expand 10 after
745 break; 745 break;
746 case GestureSourceTouchscreen: 746 case GestureSourceTouchscreen:
747 sourceDevice = WebGestureDeviceTouchscreen; 747 sourceDevice = WebGestureDeviceTouchscreen;
748 break; 748 break;
749 case GestureSourceUninitialized: 749 case GestureSourceUninitialized:
750 ASSERT_NOT_REACHED(); 750 ASSERT_NOT_REACHED();
751 } 751 }
752 } 752 }
753 753
754 } // namespace blink 754 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/fast/events/scroll-in-scaled-page-with-overflow-hidden.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698