Index: athena/home/home_card_gesture_manager_unittest.cc |
diff --git a/athena/home/home_card_gesture_manager_unittest.cc b/athena/home/home_card_gesture_manager_unittest.cc |
index aea59b813cf4a7f8cc848829ef4d78d87fb13cf0..19fc17c6165605a72f793530969cb399c21a6b35 100644 |
--- a/athena/home/home_card_gesture_manager_unittest.cc |
+++ b/athena/home/home_card_gesture_manager_unittest.cc |
@@ -46,8 +46,13 @@ class HomeCardGestureManagerTest : public test::AthenaTestBase, |
// Process a gesture event for our use case. |
bool ProcessGestureEvent(ui::EventType type, int y) { |
- ui::GestureEvent event(0, y, ui::EF_NONE, base::TimeDelta(), |
- ui::GestureEventDetails(type, 0, (y - last_y_))); |
+ ui::GestureEventDetails details; |
+ if (type == ui::ET_GESTURE_SCROLL_BEGIN || |
+ type == ui::ET_GESTURE_SCROLL_UPDATE) |
+ details = ui::GestureEventDetails(type, 0, (y - last_y_)); |
+ else |
+ details = ui::GestureEventDetails(type); |
+ ui::GestureEvent event(0, y, ui::EF_NONE, base::TimeDelta(), details); |
if (type == ui::ET_GESTURE_SCROLL_BEGIN) { |
// Compute the position that the home card would have wrt to the top of |
// the screen if the screen had screen_bounds(). |