| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/events/blink/input_handler_proxy.h" | 5 #include "ui/events/blink/input_handler_proxy.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 | 8 |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "base/test/histogram_tester.h" | 10 #include "base/test/histogram_tester.h" |
| (...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 214 return new FakeWebGestureCurve( | 214 return new FakeWebGestureCurve( |
| 215 blink::WebFloatSize(velocity.x, velocity.y), | 215 blink::WebFloatSize(velocity.x, velocity.y), |
| 216 blink::WebFloatSize(cumulative_scroll.width, cumulative_scroll.height)); | 216 blink::WebFloatSize(cumulative_scroll.width, cumulative_scroll.height)); |
| 217 } | 217 } |
| 218 | 218 |
| 219 MOCK_METHOD4(DidOverscroll, | 219 MOCK_METHOD4(DidOverscroll, |
| 220 void(const gfx::Vector2dF& accumulated_overscroll, | 220 void(const gfx::Vector2dF& accumulated_overscroll, |
| 221 const gfx::Vector2dF& latest_overscroll_delta, | 221 const gfx::Vector2dF& latest_overscroll_delta, |
| 222 const gfx::Vector2dF& current_fling_velocity, | 222 const gfx::Vector2dF& current_fling_velocity, |
| 223 const gfx::PointF& causal_event_viewport_point)); | 223 const gfx::PointF& causal_event_viewport_point)); |
| 224 void DidStartFlinging() override {} |
| 224 void DidStopFlinging() override {} | 225 void DidStopFlinging() override {} |
| 225 void DidAnimateForInput() override {} | 226 void DidAnimateForInput() override {} |
| 226 | 227 |
| 227 private: | 228 private: |
| 228 DISALLOW_COPY_AND_ASSIGN(MockInputHandlerProxyClient); | 229 DISALLOW_COPY_AND_ASSIGN(MockInputHandlerProxyClient); |
| 229 }; | 230 }; |
| 230 | 231 |
| 231 class MockInputHandlerProxyClientWithDidAnimateForInput | 232 class MockInputHandlerProxyClientWithDidAnimateForInput |
| 232 : public MockInputHandlerProxyClient { | 233 : public MockInputHandlerProxyClient { |
| 233 public: | 234 public: |
| (...skipping 2624 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2858 testing::ElementsAre(base::Bucket(1, 1), base::Bucket(3, 1), | 2859 testing::ElementsAre(base::Bucket(1, 1), base::Bucket(3, 1), |
| 2859 base::Bucket(5, 1), base::Bucket(14, 1))); | 2860 base::Bucket(5, 1), base::Bucket(14, 1))); |
| 2860 } | 2861 } |
| 2861 | 2862 |
| 2862 | 2863 |
| 2863 INSTANTIATE_TEST_CASE_P(AnimateInput, | 2864 INSTANTIATE_TEST_CASE_P(AnimateInput, |
| 2864 InputHandlerProxyTest, | 2865 InputHandlerProxyTest, |
| 2865 testing::ValuesIn(test_types)); | 2866 testing::ValuesIn(test_types)); |
| 2866 } // namespace test | 2867 } // namespace test |
| 2867 } // namespace ui | 2868 } // namespace ui |
| OLD | NEW |