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

Unified Diff: Source/core/animation/VisibilityStyleInterpolationTest.cpp

Issue 1164573002: CSSValue Immediates: Change CSSValue to an object instead of a pointer (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 5 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
Index: Source/core/animation/VisibilityStyleInterpolationTest.cpp
diff --git a/Source/core/animation/VisibilityStyleInterpolationTest.cpp b/Source/core/animation/VisibilityStyleInterpolationTest.cpp
index 3557532163af1ca7e78266d35505b2d4669df02a..74136142df27fb181a10c173276f84434d47f6d5 100644
--- a/Source/core/animation/VisibilityStyleInterpolationTest.cpp
+++ b/Source/core/animation/VisibilityStyleInterpolationTest.cpp
@@ -15,20 +15,20 @@ protected:
return VisibilityStyleInterpolation::visibilityToInterpolableValue(value);
}
- static PassRefPtrWillBeRawPtr<CSSValue> interpolableValueToVisibility(InterpolableValue* value, CSSValueID notVisible)
+ static CSSValue interpolableValueToVisibility(InterpolableValue* value, CSSValueID notVisible)
{
return VisibilityStyleInterpolation::interpolableValueToVisibility(value, notVisible);
}
- static PassRefPtrWillBeRawPtr<CSSValue> roundTrip(PassRefPtrWillBeRawPtr<CSSValue> value, CSSValueID valueID)
+ static CSSValue roundTrip(CSSValue value, CSSValueID valueID)
{
- return interpolableValueToVisibility(visibilityToInterpolableValue(*value).get(), valueID);
+ return interpolableValueToVisibility(visibilityToInterpolableValue(value).get(), valueID);
}
- static void testPrimitiveValue(PassRefPtrWillBeRawPtr<CSSValue> value, CSSValueID valueID)
+ static void testPrimitiveValue(CSSValue value, CSSValueID valueID)
{
- EXPECT_TRUE(value->isPrimitiveValue());
- EXPECT_EQ(valueID, toCSSPrimitiveValue(value.get())->getValueID());
+ EXPECT_TRUE(value.isPrimitiveValue());
+ EXPECT_EQ(valueID, toCSSPrimitiveValue(value).getValueID());
}
static InterpolableValue* getCachedValue(Interpolation& interpolation)
@@ -39,7 +39,7 @@ protected:
TEST_F(AnimationVisibilityStyleInterpolationTest, ValueIDs)
{
- RefPtrWillBeRawPtr<CSSValue> value = roundTrip(CSSPrimitiveValue::createIdentifier(CSSValueVisible), CSSValueHidden);
+ CSSValue value = roundTrip(CSSPrimitiveValue::createIdentifier(CSSValueVisible), CSSValueHidden);
testPrimitiveValue(value, CSSValueVisible);
value = roundTrip(CSSPrimitiveValue::createIdentifier(CSSValueCollapse), CSSValueCollapse);
@@ -52,12 +52,12 @@ TEST_F(AnimationVisibilityStyleInterpolationTest, ValueIDs)
TEST_F(AnimationVisibilityStyleInterpolationTest, Interpolation)
{
RefPtrWillBeRawPtr<Interpolation> interpolation = VisibilityStyleInterpolation::create(
- *CSSPrimitiveValue::createIdentifier(CSSValueHidden),
- *CSSPrimitiveValue::createIdentifier(CSSValueVisible),
+ CSSPrimitiveValue::createIdentifier(CSSValueHidden),
+ CSSPrimitiveValue::createIdentifier(CSSValueVisible),
CSSPropertyVisibility);
interpolation->interpolate(0, 0.0);
- RefPtrWillBeRawPtr<CSSValue> value = interpolableValueToVisibility(getCachedValue(*interpolation), CSSValueHidden);
+ CSSValue value = interpolableValueToVisibility(getCachedValue(*interpolation), CSSValueHidden);
testPrimitiveValue(value, CSSValueHidden);
interpolation->interpolate(0, 0.5);
« no previous file with comments | « Source/core/animation/VisibilityStyleInterpolation.cpp ('k') | Source/core/animation/animatable/AnimatableImage.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698