| 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 "content/common/input/input_param_traits.h" | 5 #include "content/common/input/input_param_traits.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| 11 #include "content/common/input/input_event.h" | 11 #include "content/common/input/input_event.h" |
| 12 #include "content/common/input/synthetic_gesture_params.h" | 12 #include "content/common/input/synthetic_gesture_params.h" |
| 13 #include "content/common/input/synthetic_pinch_gesture_params.h" | 13 #include "content/common/input/synthetic_pinch_gesture_params.h" |
| 14 #include "content/common/input/synthetic_pointer_action_list_params.h" | 14 #include "content/common/input/synthetic_pointer_action_list_params.h" |
| 15 #include "content/common/input/synthetic_pointer_action_params.h" | 15 #include "content/common/input/synthetic_pointer_action_params.h" |
| 16 #include "content/common/input/synthetic_smooth_drag_gesture_params.h" | 16 #include "content/common/input/synthetic_smooth_drag_gesture_params.h" |
| 17 #include "content/common/input/synthetic_smooth_scroll_gesture_params.h" | 17 #include "content/common/input/synthetic_smooth_scroll_gesture_params.h" |
| 18 #include "content/common/input_messages.h" | 18 #include "content/common/input_messages.h" |
| 19 #include "ipc/ipc_message.h" | 19 #include "ipc/ipc_message.h" |
| 20 #include "testing/gtest/include/gtest/gtest.h" | 20 #include "testing/gtest/include/gtest/gtest.h" |
| 21 #include "third_party/WebKit/public/platform/WebGestureEvent.h" | 21 #include "third_party/WebKit/public/platform/WebGestureEvent.h" |
| 22 #include "third_party/WebKit/public/platform/WebInputEvent.h" | 22 #include "third_party/WebKit/public/platform/WebInputEvent.h" |
| 23 #include "third_party/WebKit/public/platform/WebKeyboardEvent.h" |
| 23 #include "third_party/WebKit/public/platform/WebMouseWheelEvent.h" | 24 #include "third_party/WebKit/public/platform/WebMouseWheelEvent.h" |
| 25 #include "third_party/WebKit/public/platform/WebTouchEvent.h" |
| 24 | 26 |
| 25 namespace content { | 27 namespace content { |
| 26 namespace { | 28 namespace { |
| 27 | 29 |
| 28 typedef ScopedVector<InputEvent> InputEvents; | 30 typedef ScopedVector<InputEvent> InputEvents; |
| 29 | 31 |
| 30 class InputParamTraitsTest : public testing::Test { | 32 class InputParamTraitsTest : public testing::Test { |
| 31 protected: | 33 protected: |
| 32 static void Compare(const InputEvent* a, const InputEvent* b) { | 34 static void Compare(const InputEvent* a, const InputEvent* b) { |
| 33 EXPECT_EQ(!!a->web_event, !!b->web_event); | 35 EXPECT_EQ(!!a->web_event, !!b->web_event); |
| (...skipping 321 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 355 | 357 |
| 356 ASSERT_EQ(SyntheticGestureParams::POINTER_ACTION_LIST, | 358 ASSERT_EQ(SyntheticGestureParams::POINTER_ACTION_LIST, |
| 357 gesture_params->GetGestureType()); | 359 gesture_params->GetGestureType()); |
| 358 SyntheticGesturePacket packet_in; | 360 SyntheticGesturePacket packet_in; |
| 359 packet_in.set_gesture_params(std::move(gesture_params)); | 361 packet_in.set_gesture_params(std::move(gesture_params)); |
| 360 Verify(packet_in); | 362 Verify(packet_in); |
| 361 } | 363 } |
| 362 | 364 |
| 363 } // namespace | 365 } // namespace |
| 364 } // namespace content | 366 } // namespace content |
| OLD | NEW |