Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "content/common/input/synthetic_smooth_drag_gesture_params.h" | |
| 6 | |
| 7 #include "base/logging.h" | |
| 8 | |
| 9 namespace content { | |
| 10 | |
| 11 SyntheticSmoothDragGestureParams::SyntheticSmoothDragGestureParams() { | |
|
Sami
2015/02/23 18:03:28
Please initialize speed_in_pixels_s here. (Scroll
ssid
2015/02/23 19:10:36
Done. Scroll already does this. made this similar.
| |
| 12 } | |
| 13 | |
| 14 SyntheticSmoothDragGestureParams::SyntheticSmoothDragGestureParams( | |
| 15 const SyntheticSmoothDragGestureParams& other) | |
| 16 : SyntheticGestureParams(other), | |
| 17 start_point(other.start_point), | |
| 18 distances(other.distances), | |
| 19 speed_in_pixels_s(other.speed_in_pixels_s) { | |
| 20 } | |
| 21 | |
| 22 SyntheticSmoothDragGestureParams::~SyntheticSmoothDragGestureParams() { | |
| 23 } | |
| 24 | |
| 25 SyntheticGestureParams::GestureType | |
| 26 SyntheticSmoothDragGestureParams::GetGestureType() const { | |
| 27 return SMOOTH_DRAG_GESTURE; | |
| 28 } | |
| 29 | |
| 30 const SyntheticSmoothDragGestureParams* SyntheticSmoothDragGestureParams::Cast( | |
| 31 const SyntheticGestureParams* gesture_params) { | |
| 32 DCHECK(gesture_params); | |
| 33 DCHECK_EQ(SMOOTH_DRAG_GESTURE, gesture_params->GetGestureType()); | |
| 34 return static_cast<const SyntheticSmoothDragGestureParams*>(gesture_params); | |
| 35 } | |
| 36 | |
| 37 } // namespace content | |
| OLD | NEW |