OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004 Zack Rusin <zack@kde.org> | 2 * Copyright (C) 2004 Zack Rusin <zack@kde.org> |
3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. |
4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> | 5 * Copyright (C) 2007 Nicholas Shanks <webkit@nickshanks.com> |
6 * Copyright (C) 2011 Sencha, Inc. All rights reserved. | 6 * Copyright (C) 2011 Sencha, Inc. All rights reserved. |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Lesser General Public | 9 * modify it under the terms of the GNU Lesser General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 584 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
595 direction = cssValuePool().createIdentifierValue(CSSValueRight); | 595 direction = cssValuePool().createIdentifierValue(CSSValueRight); |
596 break; | 596 break; |
597 } | 597 } |
598 | 598 |
599 return CSSReflectValue::create(direction.release(), offset.release(), valueF
orNinePieceImage(reflection->mask(), style)); | 599 return CSSReflectValue::create(direction.release(), offset.release(), valueF
orNinePieceImage(reflection->mask(), style)); |
600 } | 600 } |
601 | 601 |
602 static PassRefPtr<CSSValueList> createPositionListForLayer(CSSPropertyID propert
yID, const FillLayer* layer, const RenderStyle* style) | 602 static PassRefPtr<CSSValueList> createPositionListForLayer(CSSPropertyID propert
yID, const FillLayer* layer, const RenderStyle* style) |
603 { | 603 { |
604 RefPtr<CSSValueList> positionList = CSSValueList::createSpaceSeparated(); | 604 RefPtr<CSSValueList> positionList = CSSValueList::createSpaceSeparated(); |
605 if (layer->isBackgroundOriginSet()) { | 605 if (layer->isBackgroundXOriginSet()) { |
606 ASSERT_UNUSED(propertyID, propertyID == CSSPropertyBackgroundPosition ||
propertyID == CSSPropertyWebkitMaskPosition); | 606 ASSERT_UNUSED(propertyID, propertyID == CSSPropertyBackgroundPosition ||
propertyID == CSSPropertyWebkitMaskPosition); |
607 positionList->append(cssValuePool().createValue(layer->backgroundXOrigin
())); | 607 positionList->append(cssValuePool().createValue(layer->backgroundXOrigin
())); |
608 } | 608 } |
609 positionList->append(zoomAdjustedPixelValueForLength(layer->xPosition(), sty
le)); | 609 positionList->append(zoomAdjustedPixelValueForLength(layer->xPosition(), sty
le)); |
610 if (layer->isBackgroundOriginSet()) { | 610 if (layer->isBackgroundYOriginSet()) { |
611 ASSERT(propertyID == CSSPropertyBackgroundPosition || propertyID == CSSP
ropertyWebkitMaskPosition); | 611 ASSERT(propertyID == CSSPropertyBackgroundPosition || propertyID == CSSP
ropertyWebkitMaskPosition); |
612 positionList->append(cssValuePool().createValue(layer->backgroundYOrigin
())); | 612 positionList->append(cssValuePool().createValue(layer->backgroundYOrigin
())); |
613 } | 613 } |
614 positionList->append(zoomAdjustedPixelValueForLength(layer->yPosition(), sty
le)); | 614 positionList->append(zoomAdjustedPixelValueForLength(layer->yPosition(), sty
le)); |
615 return positionList.release(); | 615 return positionList.release(); |
616 } | 616 } |
617 | 617 |
618 static PassRefPtr<CSSValue> valueForPositionOffset(RenderStyle* style, CSSProper
tyID propertyID, const RenderObject* renderer, RenderView* renderView) | 618 static PassRefPtr<CSSValue> valueForPositionOffset(RenderStyle* style, CSSProper
tyID propertyID, const RenderObject* renderer, RenderView* renderView) |
619 { | 619 { |
620 if (!style) | 620 if (!style) |
(...skipping 2624 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3245 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB
ackgroundSize, CSSPropertyBackgroundOrigin, | 3245 static const CSSPropertyID propertiesAfterSlashSeperator[3] = { CSSPropertyB
ackgroundSize, CSSPropertyBackgroundOrigin, |
3246 CSSPropertyB
ackgroundClip }; | 3246 CSSPropertyB
ackgroundClip }; |
3247 | 3247 |
3248 RefPtr<CSSValueList> list = CSSValueList::createSlashSeparated(); | 3248 RefPtr<CSSValueList> list = CSSValueList::createSlashSeparated(); |
3249 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash
Seperator)))); | 3249 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesBeforeSlashSeperator, WTF_ARRAY_LENGTH(propertiesBeforeSlash
Seperator)))); |
3250 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe
perator)))); | 3250 list->append(valuesForShorthandProperty(StylePropertyShorthand(CSSPropertyBa
ckground, propertiesAfterSlashSeperator, WTF_ARRAY_LENGTH(propertiesAfterSlashSe
perator)))); |
3251 return list.release(); | 3251 return list.release(); |
3252 } | 3252 } |
3253 | 3253 |
3254 } // namespace WebCore | 3254 } // namespace WebCore |
OLD | NEW |