Changeset 23558 in webkit


Ignore:
Timestamp:
Jun 15, 2007 8:14:56 PM (17 years ago)
Author:
hyatt
Message:

Fix for bugzilla bugs 14183 and 14184, 'repeat' regressed in border-image
because of a botched 'round' support removal. Also update for a change in
the spec that has the second stretch/round/repeat keyword match the first
if omitted.


Reviewed by olliej

  • css/cssparser.cpp: (WebCore::BorderImageParseContext::commitBorderImage):
  • platform/graphics/Image.cpp: (WebCore::Image::drawTiled):
  • platform/graphics/Image.h: (WebCore::Image::):
Location:
trunk/WebCore
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r23557 r23558  
     12007-06-15  David Hyatt  <hyatt@apple.com>
     2
     3        Fix for bugzilla bugs 14183 and 14184, 'repeat' regressed in border-image
     4        because of a botched 'round' support removal.  Also update for a change in
     5        the spec that has the second stretch/round/repeat keyword match the first
     6        if omitted.
     7       
     8        Reviewed by olliej
     9
     10        * css/cssparser.cpp:
     11        (WebCore::BorderImageParseContext::commitBorderImage):
     12        * platform/graphics/Image.cpp:
     13        (WebCore::Image::drawTiled):
     14        * platform/graphics/Image.h:
     15        (WebCore::Image::):
     16
    1172007-06-15  Sam Weinig  <sam@webkit.org>
    218
  • trunk/WebCore/css/cssparser.cpp

    r23557 r23558  
    28252825        if (!m_horizontalRule)
    28262826            m_horizontalRule = CSS_VAL_STRETCH;
     2827           
     2828        // The vertical rule should match the horizontal rule if unspecified.
    28272829        if (!m_verticalRule)
    2828             m_verticalRule = CSS_VAL_STRETCH;
     2830            m_verticalRule = m_horizontalRule;
    28292831
    28302832        // Make our new border image value now and add it as the result.
  • trunk/WebCore/platform/graphics/Image.cpp

    r20182 r23558  
    175175    }
    176176   
     177    // FIXME: We do not support 'round' yet.  For now just map it to 'repeat'.
     178    if (hRule == RoundTile)
     179        hRule = RepeatTile;
     180    if (vRule == RoundTile)
     181        vRule = RepeatTile;
     182
    177183    FloatSize scale = calculatePatternScale(dstRect, srcRect, hRule, vRule);
    178184    AffineTransform patternTransform = AffineTransform().scale(scale.width(), scale.height());
  • trunk/WebCore/platform/graphics/Image.h

    r20182 r23558  
    105105    ImageObserver* imageObserver() const { return m_imageObserver; }
    106106
    107     enum TileRule { StretchTile, RepeatTile };
     107    enum TileRule { StretchTile, RoundTile, RepeatTile };
    108108   
    109109#if PLATFORM(MAC)
Note: See TracChangeset for help on using the changeset viewer.