Changeset 74673 in webkit


Ignore:
Timestamp:
Dec 26, 2010 8:42:01 PM (13 years ago)
Author:
morrita@google.com
Message:

2010-12-26 MORITA Hajime <morrita@google.com>

Reviewed by Dan Bernstein.

For box-shadow, non-primary shadows should have specified radii.
https://bugs.webkit.org/show_bug.cgi?id=51386

  • fast/box-shadow/spread-multiple-normal-expected.txt: Added.
  • fast/box-shadow/spread-multiple-normal.html: Added.
  • fast/box-shadow/spread-multiple-normal-expected.checksum: Added.
  • fast/box-shadow/spread-multiple-normal-expected.png: Added.

2010-12-26 MORITA Hajime <morrita@google.com>

Reviewed by Dan Bernstein.

For box-shadow, non-primary shadows should have specified radii.
https://bugs.webkit.org/show_bug.cgi?id=51386

On paintBoxShadow(), the spread value accidentally accumulated accidentally
during the loop, which should be applied individually for radius of each shadow.
This change makes the radii for rects computed for each shadow.

Test: fast/box-shadow/spread-multiple-normal.html

  • rendering/RenderBoxModelObject.cpp: (WebCore::RenderBoxModelObject::paintBoxShadow):
Location:
trunk
Files:
4 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r74667 r74673  
     12010-12-26  MORITA Hajime  <morrita@google.com>
     2
     3        Reviewed by Dan Bernstein.
     4
     5        For box-shadow, non-primary shadows should have specified radii.
     6        https://bugs.webkit.org/show_bug.cgi?id=51386
     7
     8        * fast/box-shadow/spread-multiple-normal-expected.txt: Added.
     9        * fast/box-shadow/spread-multiple-normal.html: Added.
     10        * fast/box-shadow/spread-multiple-normal-expected.checksum: Added.
     11        * fast/box-shadow/spread-multiple-normal-expected.png: Added.
     12
    1132010-12-26  Kenneth Russell  <kbr@google.com>
    214
  • trunk/WebCore/ChangeLog

    r74671 r74673  
     12010-12-26  MORITA Hajime  <morrita@google.com>
     2
     3        Reviewed by Dan Bernstein.
     4
     5        For box-shadow, non-primary shadows should have specified radii.
     6        https://bugs.webkit.org/show_bug.cgi?id=51386
     7
     8        On paintBoxShadow(), the spread value accidentally accumulated accidentally
     9        during the loop, which should be applied individually for radius of each shadow.
     10        This change makes the radii for rects computed for each shadow.
     11       
     12        Test: fast/box-shadow/spread-multiple-normal.html
     13
     14        * rendering/RenderBoxModelObject.cpp:
     15        (WebCore::RenderBoxModelObject::paintBoxShadow):
     16
    1172010-12-26  Patrick Gansterer  <paroga@webkit.org>
    218
  • trunk/WebCore/rendering/RenderBoxModelObject.cpp

    r73729 r74673  
    17131713                IntSize bottomRightToClipOut = bottomRight;
    17141714
     1715                IntSize topLeftToFill = topLeft;
     1716                IntSize topRightToFill = topRight;
     1717                IntSize bottomLeftToFill  = bottomLeft;
     1718                IntSize bottomRightToFill = bottomRight;
    17151719                if (shadowSpread < 0)
    1716                     uniformlyExpandBorderRadii(shadowSpread, topLeft, topRight, bottomLeft, bottomRight);
     1720                    uniformlyExpandBorderRadii(shadowSpread, topLeftToFill, topRightToFill, bottomLeftToFill, bottomRightToFill);
    17171721
    17181722                // If the box is opaque, it is unnecessary to clip it out. However, doing so saves time
     
    17261730                if (!rectToClipOut.isEmpty())
    17271731                    context->clipOutRoundedRect(rectToClipOut, topLeftToClipOut, topRightToClipOut, bottomLeftToClipOut, bottomRightToClipOut);
    1728                 context->fillRoundedRect(fillRect, topLeft, topRight, bottomLeft, bottomRight, Color::black, s->colorSpace());
     1732                context->fillRoundedRect(fillRect, topLeftToFill, topRightToFill, bottomLeftToFill, bottomRightToFill, Color::black, s->colorSpace());
    17291733            } else {
    17301734                IntRect rectToClipOut = rect;
Note: See TracChangeset for help on using the changeset viewer.