summaryrefslogtreecommitdiffstats
path: root/webkit
diff options
context:
space:
mode:
authoraelias@chromium.org <aelias@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-02 01:03:00 +0000
committeraelias@chromium.org <aelias@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-02 01:03:00 +0000
commita266061701dec3deb28572be4b42e020ba6369b8 (patch)
tree12d155ade51ed81df602ab12ba132dfb112b15a8 /webkit
parent2bb40cf4931595668c10dd748ba282b2eedff1de (diff)
downloadchromium_src-a266061701dec3deb28572be4b42e020ba6369b8.zip
chromium_src-a266061701dec3deb28572be4b42e020ba6369b8.tar.gz
chromium_src-a266061701dec3deb28572be4b42e020ba6369b8.tar.bz2
Switch TouchFlingGestureCurveUnittest to use WebFloatSize.
This was a unit test I forgot to update when I originally changed the type in r186611. As a result, compile is failing after I deleted the old method in WebKit r147357, blocking the WebKit roll. NOTRY=true BUG=180331 Review URL: https://chromiumcodereview.appspot.com/13386016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@191734 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit')
-rw-r--r--webkit/glue/touch_fling_gesture_curve_unittest.cc20
1 files changed, 10 insertions, 10 deletions
diff --git a/webkit/glue/touch_fling_gesture_curve_unittest.cc b/webkit/glue/touch_fling_gesture_curve_unittest.cc
index e78ed44..0fbf101 100644
--- a/webkit/glue/touch_fling_gesture_curve_unittest.cc
+++ b/webkit/glue/touch_fling_gesture_curve_unittest.cc
@@ -9,31 +9,31 @@
#include "base/memory/scoped_ptr.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebFloatPoint.h"
+#include "third_party/WebKit/Source/Platform/chromium/public/WebFloatSize.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebGestureCurve.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebGestureCurveTarget.h"
-#include "third_party/WebKit/Source/Platform/chromium/public/WebPoint.h"
#include "third_party/WebKit/Source/Platform/chromium/public/WebSize.h"
using WebKit::WebFloatPoint;
+using WebKit::WebFloatSize;
using WebKit::WebGestureCurve;
using WebKit::WebGestureCurveTarget;
-using WebKit::WebPoint;
using WebKit::WebSize;
namespace {
class MockGestureCurveTarget : public WebGestureCurveTarget {
public:
- virtual void scrollBy(const WebPoint& delta) {
- cumulative_delta_.x += delta.x;
- cumulative_delta_.y += delta.y;
+ virtual void scrollBy(const WebFloatSize& delta) {
+ cumulative_delta_.width += delta.width;
+ cumulative_delta_.height += delta.height;
}
- WebPoint cumulative_delta() const { return cumulative_delta_; }
- void resetCumulativeDelta() { cumulative_delta_ = WebPoint(); }
+ WebFloatSize cumulative_delta() const { return cumulative_delta_; }
+ void resetCumulativeDelta() { cumulative_delta_ = WebFloatSize(); }
private:
- WebPoint cumulative_delta_;
+ WebFloatSize cumulative_delta_;
};
} // namespace anonymous
@@ -54,7 +54,7 @@ TEST(TouchFlingGestureCurve, flingCurveTouch)
EXPECT_TRUE(curve->apply(0.45f, &target)); // Use non-uniform tick spacing.
EXPECT_TRUE(curve->apply(1, &target));
EXPECT_FALSE(curve->apply(1.5, &target));
- EXPECT_NEAR(target.cumulative_delta().x, 1193, 1);
- EXPECT_EQ(target.cumulative_delta().y, 0);
+ EXPECT_NEAR(target.cumulative_delta().width, 1193, 1);
+ EXPECT_EQ(target.cumulative_delta().height, 0);
}