| 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 566 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 577 direction = cssValuePool().createIdentifierValue(CSSValueLeft); | 577 direction = cssValuePool().createIdentifierValue(CSSValueLeft); |
| 578 break; | 578 break; |
| 579 case ReflectionRight: | 579 case ReflectionRight: |
| 580 direction = cssValuePool().createIdentifierValue(CSSValueRight); | 580 direction = cssValuePool().createIdentifierValue(CSSValueRight); |
| 581 break; | 581 break; |
| 582 } | 582 } |
| 583 | 583 |
| 584 return CSSReflectValue::create(direction.release(), offset.release(), valueF
orNinePieceImage(reflection->mask(), style)); | 584 return CSSReflectValue::create(direction.release(), offset.release(), valueF
orNinePieceImage(reflection->mask(), style)); |
| 585 } | 585 } |
| 586 | 586 |
| 587 static PassRefPtrWillBeRawPtr<CSSValueList> createPositionListForLayer(CSSProper
tyID propertyID, const FillLayer* layer, const RenderStyle& style) | 587 static PassRefPtrWillBeRawPtr<CSSValueList> createPositionListForLayer(CSSProper
tyID propertyID, const FillLayer& layer, const RenderStyle& style) |
| 588 { | 588 { |
| 589 RefPtrWillBeRawPtr<CSSValueList> positionList = CSSValueList::createSpaceSep
arated(); | 589 RefPtrWillBeRawPtr<CSSValueList> positionList = CSSValueList::createSpaceSep
arated(); |
| 590 if (layer->isBackgroundXOriginSet()) { | 590 if (layer.isBackgroundXOriginSet()) { |
| 591 ASSERT_UNUSED(propertyID, propertyID == CSSPropertyBackgroundPosition ||
propertyID == CSSPropertyWebkitMaskPosition); | 591 ASSERT_UNUSED(propertyID, propertyID == CSSPropertyBackgroundPosition ||
propertyID == CSSPropertyWebkitMaskPosition); |
| 592 positionList->append(cssValuePool().createValue(layer->backgroundXOrigin
())); | 592 positionList->append(cssValuePool().createValue(layer.backgroundXOrigin(
))); |
| 593 } | 593 } |
| 594 positionList->append(zoomAdjustedPixelValueForLength(layer->xPosition(), sty
le)); | 594 positionList->append(zoomAdjustedPixelValueForLength(layer.xPosition(), styl
e)); |
| 595 if (layer->isBackgroundYOriginSet()) { | 595 if (layer.isBackgroundYOriginSet()) { |
| 596 ASSERT(propertyID == CSSPropertyBackgroundPosition || propertyID == CSSP
ropertyWebkitMaskPosition); | 596 ASSERT(propertyID == CSSPropertyBackgroundPosition || propertyID == CSSP
ropertyWebkitMaskPosition); |
| 597 positionList->append(cssValuePool().createValue(layer->backgroundYOrigin
())); | 597 positionList->append(cssValuePool().createValue(layer.backgroundYOrigin(
))); |
| 598 } | 598 } |
| 599 positionList->append(zoomAdjustedPixelValueForLength(layer->yPosition(), sty
le)); | 599 positionList->append(zoomAdjustedPixelValueForLength(layer.yPosition(), styl
e)); |
| 600 return positionList.release(); | 600 return positionList.release(); |
| 601 } | 601 } |
| 602 | 602 |
| 603 static PassRefPtrWillBeRawPtr<CSSValue> valueForPositionOffset(RenderStyle& styl
e, CSSPropertyID propertyID, const RenderObject* renderer) | 603 static PassRefPtrWillBeRawPtr<CSSValue> valueForPositionOffset(RenderStyle& styl
e, CSSPropertyID propertyID, const RenderObject* renderer) |
| 604 { | 604 { |
| 605 Length l; | 605 Length l; |
| 606 switch (propertyID) { | 606 switch (propertyID) { |
| 607 case CSSPropertyLeft: | 607 case CSSPropertyLeft: |
| 608 l = style.left(); | 608 l = style.left(); |
| 609 break; | 609 break; |
| (...skipping 1000 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1610 propertyID = CSSProperty::resolveDirectionAwareProperty(propertyID, style->d
irection(), style->writingMode()); | 1610 propertyID = CSSProperty::resolveDirectionAwareProperty(propertyID, style->d
irection(), style->writingMode()); |
| 1611 | 1611 |
| 1612 switch (propertyID) { | 1612 switch (propertyID) { |
| 1613 case CSSPropertyInvalid: | 1613 case CSSPropertyInvalid: |
| 1614 break; | 1614 break; |
| 1615 | 1615 |
| 1616 case CSSPropertyBackgroundColor: | 1616 case CSSPropertyBackgroundColor: |
| 1617 return m_allowVisitedStyle ? cssValuePool().createColorValue(style->
visitedDependentColor(CSSPropertyBackgroundColor).rgb()) : currentColorOrValidCo
lor(*style, style->backgroundColor()); | 1617 return m_allowVisitedStyle ? cssValuePool().createColorValue(style->
visitedDependentColor(CSSPropertyBackgroundColor).rgb()) : currentColorOrValidCo
lor(*style, style->backgroundColor()); |
| 1618 case CSSPropertyBackgroundImage: | 1618 case CSSPropertyBackgroundImage: |
| 1619 case CSSPropertyWebkitMaskImage: { | 1619 case CSSPropertyWebkitMaskImage: { |
| 1620 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskImage ?
style->maskLayers() : style->backgroundLayers(); | 1620 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskImage ?
style->maskLayers() : style->backgroundLayers(); |
| 1621 if (!layers) | |
| 1622 return cssValuePool().createIdentifierValue(CSSValueNone); | |
| 1623 | 1621 |
| 1624 if (!layers->next()) { | 1622 if (!layers.next()) { |
| 1625 if (layers->image()) | 1623 if (layers.image()) |
| 1626 return layers->image()->cssValue(); | 1624 return layers.image()->cssValue(); |
| 1627 | 1625 |
| 1628 return cssValuePool().createIdentifierValue(CSSValueNone); | 1626 return cssValuePool().createIdentifierValue(CSSValueNone); |
| 1629 } | 1627 } |
| 1630 | 1628 |
| 1631 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1629 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1632 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) { | 1630 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) { |
| 1633 if (currLayer->image()) | 1631 if (currLayer->image()) |
| 1634 list->append(currLayer->image()->cssValue()); | 1632 list->append(currLayer->image()->cssValue()); |
| 1635 else | 1633 else |
| 1636 list->append(cssValuePool().createIdentifierValue(CSSValueNo
ne)); | 1634 list->append(cssValuePool().createIdentifierValue(CSSValueNo
ne)); |
| 1637 } | 1635 } |
| 1638 return list.release(); | 1636 return list.release(); |
| 1639 } | 1637 } |
| 1640 case CSSPropertyBackgroundSize: | 1638 case CSSPropertyBackgroundSize: |
| 1641 case CSSPropertyWebkitBackgroundSize: | 1639 case CSSPropertyWebkitBackgroundSize: |
| 1642 case CSSPropertyWebkitMaskSize: { | 1640 case CSSPropertyWebkitMaskSize: { |
| 1643 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskSize ?
style->maskLayers() : style->backgroundLayers(); | 1641 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskSize ?
style->maskLayers() : style->backgroundLayers(); |
| 1644 if (!layers->next()) | 1642 if (!layers.next()) |
| 1645 return valueForFillSize(layers->size(), *style); | 1643 return valueForFillSize(layers.size(), *style); |
| 1646 | 1644 |
| 1647 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1645 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1648 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1646 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1649 list->append(valueForFillSize(currLayer->size(), *style)); | 1647 list->append(valueForFillSize(currLayer->size(), *style)); |
| 1650 | 1648 |
| 1651 return list.release(); | 1649 return list.release(); |
| 1652 } | 1650 } |
| 1653 case CSSPropertyBackgroundRepeat: | 1651 case CSSPropertyBackgroundRepeat: |
| 1654 case CSSPropertyWebkitMaskRepeat: { | 1652 case CSSPropertyWebkitMaskRepeat: { |
| 1655 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskRepeat
? style->maskLayers() : style->backgroundLayers(); | 1653 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskRepeat
? style->maskLayers() : style->backgroundLayers(); |
| 1656 if (!layers->next()) | 1654 if (!layers.next()) |
| 1657 return valueForFillRepeat(layers->repeatX(), layers->repeatY()); | 1655 return valueForFillRepeat(layers.repeatX(), layers.repeatY()); |
| 1658 | 1656 |
| 1659 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1657 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1660 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1658 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1661 list->append(valueForFillRepeat(currLayer->repeatX(), currLayer-
>repeatY())); | 1659 list->append(valueForFillRepeat(currLayer->repeatX(), currLayer-
>repeatY())); |
| 1662 | 1660 |
| 1663 return list.release(); | 1661 return list.release(); |
| 1664 } | 1662 } |
| 1665 case CSSPropertyMaskSourceType: { | 1663 case CSSPropertyMaskSourceType: { |
| 1666 const FillLayer* layers = style->maskLayers(); | 1664 const FillLayer& layers = style->maskLayers(); |
| 1667 | 1665 |
| 1668 if (!layers) | 1666 if (!layers.next()) |
| 1669 return cssValuePool().createIdentifierValue(CSSValueNone); | 1667 return valueForFillSourceType(layers.maskSourceType()); |
| 1670 | |
| 1671 if (!layers->next()) | |
| 1672 return valueForFillSourceType(layers->maskSourceType()); | |
| 1673 | 1668 |
| 1674 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1669 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1675 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1670 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1676 list->append(valueForFillSourceType(currLayer->maskSourceType())
); | 1671 list->append(valueForFillSourceType(currLayer->maskSourceType())
); |
| 1677 | 1672 |
| 1678 return list.release(); | 1673 return list.release(); |
| 1679 } | 1674 } |
| 1680 case CSSPropertyWebkitBackgroundComposite: | 1675 case CSSPropertyWebkitBackgroundComposite: |
| 1681 case CSSPropertyWebkitMaskComposite: { | 1676 case CSSPropertyWebkitMaskComposite: { |
| 1682 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskComposi
te ? style->maskLayers() : style->backgroundLayers(); | 1677 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskComposi
te ? style->maskLayers() : style->backgroundLayers(); |
| 1683 if (!layers->next()) | 1678 if (!layers.next()) |
| 1684 return cssValuePool().createValue(layers->composite()); | 1679 return cssValuePool().createValue(layers.composite()); |
| 1685 | 1680 |
| 1686 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1681 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1687 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1682 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1688 list->append(cssValuePool().createValue(currLayer->composite()))
; | 1683 list->append(cssValuePool().createValue(currLayer->composite()))
; |
| 1689 | 1684 |
| 1690 return list.release(); | 1685 return list.release(); |
| 1691 } | 1686 } |
| 1692 case CSSPropertyBackgroundAttachment: { | 1687 case CSSPropertyBackgroundAttachment: { |
| 1693 const FillLayer* layers = style->backgroundLayers(); | 1688 const FillLayer& layers = style->backgroundLayers(); |
| 1694 if (!layers->next()) | 1689 if (!layers.next()) |
| 1695 return cssValuePool().createValue(layers->attachment()); | 1690 return cssValuePool().createValue(layers.attachment()); |
| 1696 | 1691 |
| 1697 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1692 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1698 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1693 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1699 list->append(cssValuePool().createValue(currLayer->attachment())
); | 1694 list->append(cssValuePool().createValue(currLayer->attachment())
); |
| 1700 | 1695 |
| 1701 return list.release(); | 1696 return list.release(); |
| 1702 } | 1697 } |
| 1703 case CSSPropertyBackgroundClip: | 1698 case CSSPropertyBackgroundClip: |
| 1704 case CSSPropertyBackgroundOrigin: | 1699 case CSSPropertyBackgroundOrigin: |
| 1705 case CSSPropertyWebkitBackgroundClip: | 1700 case CSSPropertyWebkitBackgroundClip: |
| 1706 case CSSPropertyWebkitBackgroundOrigin: | 1701 case CSSPropertyWebkitBackgroundOrigin: |
| 1707 case CSSPropertyWebkitMaskClip: | 1702 case CSSPropertyWebkitMaskClip: |
| 1708 case CSSPropertyWebkitMaskOrigin: { | 1703 case CSSPropertyWebkitMaskOrigin: { |
| 1709 const FillLayer* layers = (propertyID == CSSPropertyWebkitMaskClip |
| propertyID == CSSPropertyWebkitMaskOrigin) ? style->maskLayers() : style->back
groundLayers(); | 1704 const FillLayer& layers = (propertyID == CSSPropertyWebkitMaskClip |
| propertyID == CSSPropertyWebkitMaskOrigin) ? style->maskLayers() : style->back
groundLayers(); |
| 1710 bool isClip = propertyID == CSSPropertyBackgroundClip || propertyID
== CSSPropertyWebkitBackgroundClip || propertyID == CSSPropertyWebkitMaskClip; | 1705 bool isClip = propertyID == CSSPropertyBackgroundClip || propertyID
== CSSPropertyWebkitBackgroundClip || propertyID == CSSPropertyWebkitMaskClip; |
| 1711 if (!layers->next()) { | 1706 if (!layers.next()) { |
| 1712 EFillBox box = isClip ? layers->clip() : layers->origin(); | 1707 EFillBox box = isClip ? layers.clip() : layers.origin(); |
| 1713 return cssValuePool().createValue(box); | 1708 return cssValuePool().createValue(box); |
| 1714 } | 1709 } |
| 1715 | 1710 |
| 1716 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1711 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1717 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) { | 1712 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) { |
| 1718 EFillBox box = isClip ? currLayer->clip() : currLayer->origin(); | 1713 EFillBox box = isClip ? currLayer->clip() : currLayer->origin(); |
| 1719 list->append(cssValuePool().createValue(box)); | 1714 list->append(cssValuePool().createValue(box)); |
| 1720 } | 1715 } |
| 1721 | 1716 |
| 1722 return list.release(); | 1717 return list.release(); |
| 1723 } | 1718 } |
| 1724 case CSSPropertyBackgroundPosition: | 1719 case CSSPropertyBackgroundPosition: |
| 1725 case CSSPropertyWebkitMaskPosition: { | 1720 case CSSPropertyWebkitMaskPosition: { |
| 1726 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskPositio
n ? style->maskLayers() : style->backgroundLayers(); | 1721 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskPositio
n ? style->maskLayers() : style->backgroundLayers(); |
| 1727 if (!layers->next()) | 1722 if (!layers.next()) |
| 1728 return createPositionListForLayer(propertyID, layers, *style); | 1723 return createPositionListForLayer(propertyID, layers, *style); |
| 1729 | 1724 |
| 1730 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1725 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1731 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1726 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1732 list->append(createPositionListForLayer(propertyID, currLayer, *
style)); | 1727 list->append(createPositionListForLayer(propertyID, *currLayer,
*style)); |
| 1733 return list.release(); | 1728 return list.release(); |
| 1734 } | 1729 } |
| 1735 case CSSPropertyBackgroundPositionX: | 1730 case CSSPropertyBackgroundPositionX: |
| 1736 case CSSPropertyWebkitMaskPositionX: { | 1731 case CSSPropertyWebkitMaskPositionX: { |
| 1737 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskPositio
nX ? style->maskLayers() : style->backgroundLayers(); | 1732 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskPositio
nX ? style->maskLayers() : style->backgroundLayers(); |
| 1738 if (!layers->next()) | 1733 if (!layers.next()) |
| 1739 return zoomAdjustedPixelValueForLength(layers->xPosition(), *sty
le); | 1734 return zoomAdjustedPixelValueForLength(layers.xPosition(), *styl
e); |
| 1740 | 1735 |
| 1741 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1736 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1742 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1737 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1743 list->append(zoomAdjustedPixelValueForLength(currLayer->xPositio
n(), *style)); | 1738 list->append(zoomAdjustedPixelValueForLength(currLayer->xPositio
n(), *style)); |
| 1744 | 1739 |
| 1745 return list.release(); | 1740 return list.release(); |
| 1746 } | 1741 } |
| 1747 case CSSPropertyBackgroundPositionY: | 1742 case CSSPropertyBackgroundPositionY: |
| 1748 case CSSPropertyWebkitMaskPositionY: { | 1743 case CSSPropertyWebkitMaskPositionY: { |
| 1749 const FillLayer* layers = propertyID == CSSPropertyWebkitMaskPositio
nY ? style->maskLayers() : style->backgroundLayers(); | 1744 const FillLayer& layers = propertyID == CSSPropertyWebkitMaskPositio
nY ? style->maskLayers() : style->backgroundLayers(); |
| 1750 if (!layers->next()) | 1745 if (!layers.next()) |
| 1751 return zoomAdjustedPixelValueForLength(layers->yPosition(), *sty
le); | 1746 return zoomAdjustedPixelValueForLength(layers.yPosition(), *styl
e); |
| 1752 | 1747 |
| 1753 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 1748 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 1754 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 1749 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 1755 list->append(zoomAdjustedPixelValueForLength(currLayer->yPositio
n(), *style)); | 1750 list->append(zoomAdjustedPixelValueForLength(currLayer->yPositio
n(), *style)); |
| 1756 | 1751 |
| 1757 return list.release(); | 1752 return list.release(); |
| 1758 } | 1753 } |
| 1759 case CSSPropertyBorderCollapse: | 1754 case CSSPropertyBorderCollapse: |
| 1760 if (style->borderCollapse()) | 1755 if (style->borderCollapse()) |
| 1761 return cssValuePool().createIdentifierValue(CSSValueCollapse); | 1756 return cssValuePool().createIdentifierValue(CSSValueCollapse); |
| 1762 return cssValuePool().createIdentifierValue(CSSValueSeparate); | 1757 return cssValuePool().createIdentifierValue(CSSValueSeparate); |
| 1763 case CSSPropertyBorderSpacing: { | 1758 case CSSPropertyBorderSpacing: { |
| 1764 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSep
arated(); | 1759 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createSpaceSep
arated(); |
| (...skipping 970 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2735 case CSSPropertyShapeImageThreshold: | 2730 case CSSPropertyShapeImageThreshold: |
| 2736 return cssValuePool().createValue(style->shapeImageThreshold(), CSSP
rimitiveValue::CSS_NUMBER); | 2731 return cssValuePool().createValue(style->shapeImageThreshold(), CSSP
rimitiveValue::CSS_NUMBER); |
| 2737 case CSSPropertyShapeOutside: | 2732 case CSSPropertyShapeOutside: |
| 2738 return valueForShape(*style, style->shapeOutside()); | 2733 return valueForShape(*style, style->shapeOutside()); |
| 2739 case CSSPropertyWebkitFilter: | 2734 case CSSPropertyWebkitFilter: |
| 2740 return valueForFilter(renderer, *style); | 2735 return valueForFilter(renderer, *style); |
| 2741 case CSSPropertyMixBlendMode: | 2736 case CSSPropertyMixBlendMode: |
| 2742 return cssValuePool().createValue(style->blendMode()); | 2737 return cssValuePool().createValue(style->blendMode()); |
| 2743 | 2738 |
| 2744 case CSSPropertyBackgroundBlendMode: { | 2739 case CSSPropertyBackgroundBlendMode: { |
| 2745 const FillLayer* layers = style->backgroundLayers(); | 2740 const FillLayer& layers = style->backgroundLayers(); |
| 2746 if (!layers->next()) | 2741 if (!layers.next()) |
| 2747 return cssValuePool().createValue(layers->blendMode()); | 2742 return cssValuePool().createValue(layers.blendMode()); |
| 2748 | 2743 |
| 2749 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); | 2744 RefPtrWillBeRawPtr<CSSValueList> list = CSSValueList::createCommaSep
arated(); |
| 2750 for (const FillLayer* currLayer = layers; currLayer; currLayer = cur
rLayer->next()) | 2745 for (const FillLayer* currLayer = &layers; currLayer; currLayer = cu
rrLayer->next()) |
| 2751 list->append(cssValuePool().createValue(currLayer->blendMode()))
; | 2746 list->append(cssValuePool().createValue(currLayer->blendMode()))
; |
| 2752 | 2747 |
| 2753 return list.release(); | 2748 return list.release(); |
| 2754 } | 2749 } |
| 2755 case CSSPropertyBackground: | 2750 case CSSPropertyBackground: |
| 2756 return valuesForBackgroundShorthand(); | 2751 return valuesForBackgroundShorthand(); |
| 2757 case CSSPropertyBorder: { | 2752 case CSSPropertyBorder: { |
| 2758 RefPtrWillBeRawPtr<CSSValue> value = getPropertyCSSValue(CSSProperty
BorderTop, DoNotUpdateLayout); | 2753 RefPtrWillBeRawPtr<CSSValue> value = getPropertyCSSValue(CSSProperty
BorderTop, DoNotUpdateLayout); |
| 2759 const CSSPropertyID properties[3] = { CSSPropertyBorderRight, CSSPro
pertyBorderBottom, | 2754 const CSSPropertyID properties[3] = { CSSPropertyBorderRight, CSSPro
pertyBorderBottom, |
| 2760 CSSPropertyBorderLeft }; | 2755 CSSPropertyBorderLeft }; |
| (...skipping 372 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3133 return list.release(); | 3128 return list.release(); |
| 3134 } | 3129 } |
| 3135 | 3130 |
| 3136 void CSSComputedStyleDeclaration::trace(Visitor* visitor) | 3131 void CSSComputedStyleDeclaration::trace(Visitor* visitor) |
| 3137 { | 3132 { |
| 3138 visitor->trace(m_node); | 3133 visitor->trace(m_node); |
| 3139 CSSStyleDeclaration::trace(visitor); | 3134 CSSStyleDeclaration::trace(visitor); |
| 3140 } | 3135 } |
| 3141 | 3136 |
| 3142 } // namespace WebCore | 3137 } // namespace WebCore |
| OLD | NEW |