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

Unified Diff: content/common/input/web_input_event_traits_unittest.cc

Issue 819993002: Revert of Explicitly suppress scrolling for wheel events that will trigger zooming (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years 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 | « content/common/input/web_input_event_traits.cc ('k') | content/renderer/input/input_handler_proxy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/common/input/web_input_event_traits_unittest.cc
diff --git a/content/common/input/web_input_event_traits_unittest.cc b/content/common/input/web_input_event_traits_unittest.cc
index d4bbeba8a70b0dbf949559c86087ac74ee03186a..7a7cb7ff8b3e878eec275c8445494fbb8a6aefa4 100644
--- a/content/common/input/web_input_event_traits_unittest.cc
+++ b/content/common/input/web_input_event_traits_unittest.cc
@@ -49,17 +49,6 @@
event.type = type;
event.x = x;
event.y = y;
- return event;
- }
-
- static WebMouseWheelEvent CreateMouseWheel(float deltaX,
- float deltaY,
- bool canScroll) {
- WebMouseWheelEvent event;
- event.type = WebInputEvent::MouseWheel;
- event.deltaX = deltaX;
- event.deltaY = deltaY;
- event.canScroll = canScroll;
return event;
}
};
@@ -173,31 +162,6 @@
EXPECT_EQ(numeric_limits<float>::max(), pinch1.data.pinchUpdate.scale);
}
-TEST_F(WebInputEventTraitsTest, WebMouseWheelEventCoalescing) {
- WebMouseWheelEvent mouseWheel0 =
- CreateMouseWheel(1, 1, true);
- WebMouseWheelEvent mouseWheel1 =
- CreateMouseWheel(2, 2, true);
-
- // WebMouseWheelEvent objects with same values except different deltaX and
- // deltaY should coalesce.
- EXPECT_TRUE(WebInputEventTraits::CanCoalesce(mouseWheel0, mouseWheel1));
-
- mouseWheel0 = CreateMouseWheel(1, 1, true);
- mouseWheel1 = CreateMouseWheel(1, 1, false);
-
- // WebMouseWheelEvent objects with different canScroll values should not
- // coalesce.
- EXPECT_FALSE(WebInputEventTraits::CanCoalesce(mouseWheel0, mouseWheel1));
-
- // WebMouseWheelEvent objects with different modifiers should not coalesce.
- mouseWheel0 = CreateMouseWheel(1, 1, true);
- mouseWheel1 = CreateMouseWheel(1, 1, true);
- mouseWheel0.modifiers = blink::WebInputEvent::ControlKey;
- mouseWheel1.modifiers = blink::WebInputEvent::ShiftKey;
- EXPECT_FALSE(WebInputEventTraits::CanCoalesce(mouseWheel0, mouseWheel1));
-}
-
// Very basic smoke test to ensure stringification doesn't explode.
TEST_F(WebInputEventTraitsTest, ToString) {
WebKeyboardEvent key;
« no previous file with comments | « content/common/input/web_input_event_traits.cc ('k') | content/renderer/input/input_handler_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698