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

Unified Diff: cc/keyframed_animation_curve_unittest.cc

Issue 12035029: Finish migrating cc/ from WebKit::WebTransformationMatrix to gfx::Transform (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix nits Created 7 years, 11 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 | « cc/keyframed_animation_curve.cc ('k') | cc/layer_animation_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/keyframed_animation_curve_unittest.cc
diff --git a/cc/keyframed_animation_curve_unittest.cc b/cc/keyframed_animation_curve_unittest.cc
index a08ada691dfb3987544ecaa21a2bdd7993ec9336..2809190281ee121e95a2dbd9907bd61820b77094 100644
--- a/cc/keyframed_animation_curve_unittest.cc
+++ b/cc/keyframed_animation_curve_unittest.cc
@@ -7,16 +7,13 @@
#include "cc/transform_operations.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
-#include "third_party/WebKit/Source/Platform/chromium/public/WebTransformationMatrix.h"
-
-using WebKit::WebTransformationMatrix;
namespace cc {
namespace {
-void expectTranslateX(double translateX, const WebTransformationMatrix& matrix)
+void expectTranslateX(double translateX, const gfx::Transform& transform)
{
- EXPECT_FLOAT_EQ(translateX, matrix.m41());
+ EXPECT_FLOAT_EQ(translateX, transform.matrix().getDouble(0, 3));
}
// Tests that a float animation with one keyframe works as expected.
@@ -161,8 +158,8 @@ TEST(KeyframedAnimationCurveTest, RepeatedTransformKeyTimes)
expectTranslateX(4, curve->getValue(0.5));
// There is a discontinuity at 1. Any value between 4 and 6 is valid.
- WebTransformationMatrix value = curve->getValue(1);
- EXPECT_TRUE(value.m41() >= 4 && value.m41() <= 6);
+ gfx::Transform value = curve->getValue(1);
+ EXPECT_TRUE(value.matrix().getDouble(0, 3) >= 4 && value.matrix().getDouble(0, 3) <= 6);
expectTranslateX(6, curve->getValue(1.5));
expectTranslateX(6, curve->getValue(2));
« no previous file with comments | « cc/keyframed_animation_curve.cc ('k') | cc/layer_animation_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698