OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/gesture_detection/scale_gesture_detector.h" | 5 #include "ui/events/gesture_detection/scale_gesture_detector.h" |
6 | 6 |
7 #include <limits.h> | 7 #include <limits.h> |
8 | 8 |
| 9 #include <algorithm> |
9 #include <cmath> | 10 #include <cmath> |
10 | 11 |
11 #include "base/logging.h" | 12 #include "base/logging.h" |
12 #include "ui/events/gesture_detection/motion_event.h" | 13 #include "ui/events/gesture_detection/motion_event.h" |
13 #include "ui/events/gesture_detection/scale_gesture_listeners.h" | 14 #include "ui/events/gesture_detection/scale_gesture_listeners.h" |
14 | 15 |
15 using base::TimeDelta; | 16 using base::TimeDelta; |
16 using base::TimeTicks; | 17 using base::TimeTicks; |
17 | 18 |
18 namespace ui { | 19 namespace ui { |
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
364 touch_history_last_accepted_time_ = base::TimeTicks(); | 365 touch_history_last_accepted_time_ = base::TimeTicks(); |
365 } | 366 } |
366 | 367 |
367 void ScaleGestureDetector::ResetScaleWithSpan(float span) { | 368 void ScaleGestureDetector::ResetScaleWithSpan(float span) { |
368 in_progress_ = false; | 369 in_progress_ = false; |
369 initial_span_ = span; | 370 initial_span_ = span; |
370 anchored_scale_mode_ = ANCHORED_SCALE_MODE_NONE; | 371 anchored_scale_mode_ = ANCHORED_SCALE_MODE_NONE; |
371 } | 372 } |
372 | 373 |
373 } // namespace ui | 374 } // namespace ui |
OLD | NEW |