Changeset 120602 in webkit


Ignore:
Timestamp:
Jun 18, 2012 9:40:07 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

webkit fails IETC border-radius-clip-002
https://bugs.webkit.org/show_bug.cgi?id=83205

Source/WebCore:

Added addRoundedRectClip instead of just clip when clipToBorderRadius
is true and bgLayer->clip() == ContentFillBox.

Patch by Takashi Sakamoto <tasak@google.com> on 2012-06-18
Reviewed by Simon Fraser.

This change is covered by the existing test: ietestcenter/css3/bordersbackgrounds/border-radius-clip-002.
However expected images should be updated. I updated chromium-linux
and chromium-mac's expected images and removed chromium-win,
chromium-mac-leopard and chromium-mac-snowleopard's expected images.

  • rendering/RenderBoxModelObject.cpp:

(WebCore::RenderBoxModelObject::paintFillLayerExtended):
As the code for "clipping to content boxes as necessary" doesn't
consider border-radius or not, added the code for checking
clipToBorderRadius or not, and if so, modified to use
getBackgroundRoundedRect for obtaining rounded rect and to use
addRoundedRectClip by using the obtained rounded rect.

LayoutTests:

Patch by Takashi Sakamoto <tasak@google.com> on 2012-06-18
Reviewed by Simon Fraser.

  • platform/chromium-linux/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png:
  • platform/chromium-mac/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png:
  • platform/chromium-mac-leopard/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png: Removed.
  • platform/chromium-mac-snowleopard/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png: Removed.
  • platform/chromium-win/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png: Removed.
Location:
trunk
Files:
3 deleted
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r120601 r120602  
     12012-06-18  Takashi Sakamoto  <tasak@google.com>
     2
     3        webkit fails IETC border-radius-clip-002
     4        https://bugs.webkit.org/show_bug.cgi?id=83205
     5
     6        Reviewed by Simon Fraser.
     7
     8        * platform/chromium-linux/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png:
     9        * platform/chromium-mac/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png:
     10        * platform/chromium-mac-leopard/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png: Removed.
     11        * platform/chromium-mac-snowleopard/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png: Removed.
     12        * platform/chromium-win/ietestcenter/css3/bordersbackgrounds/border-radius-clip-002-expected.png: Removed.
     13
    1142012-06-18  Iain Merrick  <husky@google.com>
    215
  • trunk/Source/WebCore/ChangeLog

    r120601 r120602  
     12012-06-18  Takashi Sakamoto  <tasak@google.com>
     2
     3        webkit fails IETC border-radius-clip-002
     4        https://bugs.webkit.org/show_bug.cgi?id=83205
     5
     6        Added addRoundedRectClip instead of just clip when clipToBorderRadius
     7        is true and bgLayer->clip() == ContentFillBox.
     8
     9        Reviewed by Simon Fraser.
     10
     11        This change is covered by the existing test: ietestcenter/css3/bordersbackgrounds/border-radius-clip-002.
     12        However expected images should be updated. I updated chromium-linux
     13        and chromium-mac's expected images and removed chromium-win,
     14        chromium-mac-leopard and chromium-mac-snowleopard's expected images.
     15
     16        * rendering/RenderBoxModelObject.cpp:
     17        (WebCore::RenderBoxModelObject::paintFillLayerExtended):
     18        As the code for "clipping to content boxes as necessary" doesn't
     19        consider border-radius or not, added the code for checking
     20        clipToBorderRadius or not, and if so, modified to use
     21        getBackgroundRoundedRect for obtaining rounded rect and to use
     22        addRoundedRectClip by using the obtained rounded rect.
     23
    1242012-06-18  Iain Merrick  <husky@google.com>
    225
  • trunk/Source/WebCore/rendering/RenderBoxModelObject.cpp

    r120495 r120602  
    812812                                   scrolledPaintRect.height() - borderTop() - borderBottom() - (includePadding ? paddingTop() + paddingBottom() : ZERO_LAYOUT_UNIT));
    813813        backgroundClipStateSaver.save();
    814         context->clip(clipRect);
     814        if (clipToBorderRadius && includePadding) {
     815            RoundedRect rounded = getBackgroundRoundedRect(clipRect, box, boxSize.width(), boxSize.height(), includeLeftEdge, includeRightEdge);
     816            context->addRoundedRectClip(rounded);
     817        } else
     818            context->clip(clipRect);
    815819    } else if (bgLayer->clip() == TextFillBox) {
    816820        // We have to draw our text into a mask that can then be used to clip background drawing.
Note: See TracChangeset for help on using the changeset viewer.