Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(106)

Unified Diff: ui/events/gesture_detection/scale_gesture_detector.cc

Issue 1076443002: Removed obsolete float_util.h as VS2013 supports standards well enough. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Fixed mistake in value converter. Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/blink/websourcebuffer_impl.cc ('k') | ui/gfx/range/range_f.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/gesture_detection/scale_gesture_detector.cc
diff --git a/ui/events/gesture_detection/scale_gesture_detector.cc b/ui/events/gesture_detection/scale_gesture_detector.cc
index 676d6a428183fc79730e12a2616e7a9f9fd5a4a6..fb27cd9458e11829cb12669c70a6ddae165f1d4a 100644
--- a/ui/events/gesture_detection/scale_gesture_detector.cc
+++ b/ui/events/gesture_detection/scale_gesture_detector.cc
@@ -5,9 +5,9 @@
#include "ui/events/gesture_detection/scale_gesture_detector.h"
#include <limits.h>
+
#include <cmath>
-#include "base/float_util.h"
#include "base/logging.h"
#include "ui/events/gesture_detection/motion_event.h"
#include "ui/events/gesture_detection/scale_gesture_listeners.h"
@@ -286,7 +286,7 @@ void ScaleGestureDetector::AddTouchHistory(const MotionEvent& ev) {
float total = 0;
int sample_count = 0;
for (int i = 0; i < count; i++) {
- const bool has_last_accepted = !base::IsNaN(touch_history_last_accepted_);
+ const bool has_last_accepted = !std::isnan(touch_history_last_accepted_);
const int history_size = static_cast<int>(ev.GetHistorySize());
const int pointersample_count = history_size + 1;
for (int h = 0; h < pointersample_count; h++) {
@@ -302,10 +302,10 @@ void ScaleGestureDetector::AddTouchHistory(const MotionEvent& ev) {
major = touch_max_major_;
total += major;
- if (base::IsNaN(touch_upper_) || major > touch_upper_) {
+ if (std::isnan(touch_upper_) || major > touch_upper_) {
touch_upper_ = major;
}
- if (base::IsNaN(touch_lower_) || major < touch_lower_) {
+ if (std::isnan(touch_lower_) || major < touch_lower_) {
touch_lower_ = major;
}
« no previous file with comments | « media/blink/websourcebuffer_impl.cc ('k') | ui/gfx/range/range_f.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698