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

Unified Diff: Source/core/css/CSSComputedStyleDeclaration.cpp

Issue 38573003: Use 4 value syntax for getComputedStyle of background-position and -webkit-mask-position (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebased Created 7 years, 1 month 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 | « LayoutTests/virtual/web-animations-css/animations/interpolation/webkit-mask-position-interpolation-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/CSSComputedStyleDeclaration.cpp
diff --git a/Source/core/css/CSSComputedStyleDeclaration.cpp b/Source/core/css/CSSComputedStyleDeclaration.cpp
index b7c91f43563f23b746da26e9963946c2511a5de2..25043b7aac7d4125b4d1e94349b1cd5b8dfd209d 100644
--- a/Source/core/css/CSSComputedStyleDeclaration.cpp
+++ b/Source/core/css/CSSComputedStyleDeclaration.cpp
@@ -601,16 +601,11 @@ static PassRefPtr<CSSValue> valueForReflection(const StyleReflection* reflection
static PassRefPtr<CSSValueList> createPositionListForLayer(CSSPropertyID propertyID, const FillLayer* layer, const RenderStyle* style)
{
+ ASSERT_UNUSED(propertyID, propertyID == CSSPropertyBackgroundPosition || propertyID == CSSPropertyWebkitMaskPosition);
RefPtr<CSSValueList> positionList = CSSValueList::createSpaceSeparated();
- if (layer->isBackgroundXOriginSet()) {
- ASSERT_UNUSED(propertyID, propertyID == CSSPropertyBackgroundPosition || propertyID == CSSPropertyWebkitMaskPosition);
- positionList->append(cssValuePool().createValue(layer->backgroundXOrigin()));
- }
+ positionList->append(cssValuePool().createValue(layer->backgroundXOrigin()));
positionList->append(zoomAdjustedPixelValueForLength(layer->xPosition(), style));
- if (layer->isBackgroundYOriginSet()) {
- ASSERT(propertyID == CSSPropertyBackgroundPosition || propertyID == CSSPropertyWebkitMaskPosition);
- positionList->append(cssValuePool().createValue(layer->backgroundYOrigin()));
- }
+ positionList->append(cssValuePool().createValue(layer->backgroundYOrigin()));
positionList->append(zoomAdjustedPixelValueForLength(layer->yPosition(), style));
return positionList.release();
}
« no previous file with comments | « LayoutTests/virtual/web-animations-css/animations/interpolation/webkit-mask-position-interpolation-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698