Changeset 165587 in webkit


Ignore:
Timestamp:
Mar 13, 2014 6:41:31 PM (10 years ago)
Author:
dbates@webkit.org
Message:

REGRESSION (r160806): Incorrect cascade order of prefixed and non-prefixed variants of
CSS properties box-shadow and background-{clip, origin, size}
https://bugs.webkit.org/show_bug.cgi?id=130102
<rdar://problem/16187037>

Reviewed by Andreas Kling.

Source/WebCore:

Fixes an issues in the computation of the final value for the CSS properties
box-shadow and background-{clip, origin, size} when the definition of a selector
uses both the prefixed and non-prefixed variants (in order) of these properties.

Tests: fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order.html

fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order.html
fast/css/cascade/background-size-and-webkit-background-size-cascade-order.html
fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order.html

  • css/CSSPropertyNames.in: Add a comment to explain the difference between property

-webkit-box-shadow and property box-shadow.

  • css/StyleResolver.cpp:

(WebCore::shouldApplyPropertyInParseOrder): Add prefixed and non-prefixed variants
of box-shadow and background-{clip, origin, size} to the list of properties that need
to be applied in the same order as they were parsed from the stylesheet.

LayoutTests:

Add tests to ensure that we correctly cascade the prefixed and non-prefixed variants
of the CSS properties box-shadow and background-{clip, origin, size}.

  • fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order-expected.html: Added.
  • fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order.html: Added.
  • fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order-expected.html: Added.
  • fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order.html: Added.
  • fast/css/cascade/background-size-and-webkit-background-size-cascade-order-expected.html: Added.
  • fast/css/cascade/background-size-and-webkit-background-size-cascade-order.html: Added.
  • fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order-expected.html: Added.
  • fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order.html: Added.
  • fast/css/resources/green-128x128.png: Added.
  • fast/css/resources/green-square-above-red-square.png: Added.
  • fast/css/resources/red-square-above-green-square.png: Added.
  • fast/css/resources/red-square-in-green-square.png: Added.
Location:
trunk
Files:
13 added
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/ChangeLog

    r165581 r165587  
     12014-03-13  Daniel Bates  <dabates@apple.com>
     2
     3        REGRESSION (r160806): Incorrect cascade order of prefixed and non-prefixed variants of
     4        CSS properties box-shadow and background-{clip, origin, size}
     5        https://bugs.webkit.org/show_bug.cgi?id=130102
     6        <rdar://problem/16187037>
     7
     8        Reviewed by Andreas Kling.
     9
     10        Add tests to ensure that we correctly cascade the prefixed and non-prefixed variants
     11        of the CSS properties box-shadow and background-{clip, origin, size}.
     12
     13        * fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order-expected.html: Added.
     14        * fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order.html: Added.
     15        * fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order-expected.html: Added.
     16        * fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order.html: Added.
     17        * fast/css/cascade/background-size-and-webkit-background-size-cascade-order-expected.html: Added.
     18        * fast/css/cascade/background-size-and-webkit-background-size-cascade-order.html: Added.
     19        * fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order-expected.html: Added.
     20        * fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order.html: Added.
     21        * fast/css/resources/green-128x128.png: Added.
     22        * fast/css/resources/green-square-above-red-square.png: Added.
     23        * fast/css/resources/red-square-above-green-square.png: Added.
     24        * fast/css/resources/red-square-in-green-square.png: Added.
     25
    1262014-03-13  Commit Queue  <commit-queue@webkit.org>
    227
  • trunk/Source/WebCore/ChangeLog

    r165584 r165587  
     12014-03-13  Daniel Bates  <dabates@apple.com>
     2
     3        REGRESSION (r160806): Incorrect cascade order of prefixed and non-prefixed variants of
     4        CSS properties box-shadow and background-{clip, origin, size}
     5        https://bugs.webkit.org/show_bug.cgi?id=130102
     6        <rdar://problem/16187037>
     7
     8        Reviewed by Andreas Kling.
     9
     10        Fixes an issues in the computation of the final value for the CSS properties
     11        box-shadow and background-{clip, origin, size} when the definition of a selector
     12        uses both the prefixed and non-prefixed variants (in order) of these properties.
     13
     14        Tests: fast/css/cascade/background-clip-and-webkit-background-clip-cascade-order.html
     15               fast/css/cascade/background-origin-and-webkit-background-origin-cascade-order.html
     16               fast/css/cascade/background-size-and-webkit-background-size-cascade-order.html
     17               fast/css/cascade/box-shadow-and-webkit-box-shadow-cascade-order.html
     18
     19        * css/CSSPropertyNames.in: Add a comment to explain the difference between property
     20        -webkit-box-shadow and property box-shadow.
     21        * css/StyleResolver.cpp:
     22        (WebCore::shouldApplyPropertyInParseOrder): Add prefixed and non-prefixed variants
     23        of box-shadow and background-{clip, origin, size} to the list of properties that need
     24        to be applied in the same order as they were parsed from the stylesheet.
     25
    1262014-03-13  Joseph Pecoraro  <pecoraro@apple.com>
    227
  • trunk/Source/WebCore/css/CSSPropertyNames.in

    r164795 r165587  
    262262-webkit-box-pack
    263263-webkit-box-reflect
     264// -webkit-box-shadow differs from box-shadow in its treatement of blur radii > 8px.
     265// Let -webkit-box-shadow blur radius be w_r and box-shadow blur radius be b_r. For
     266// w_r > 8px, b_r = 8 + 4 * sqrt((w_r - 8) / 2).
    264267-webkit-box-shadow
    265268-webkit-color-correction [Inherited]
  • trunk/Source/WebCore/css/StyleResolver.cpp

    r165557 r165587  
    15961596{
    15971597    switch (propertyID) {
     1598    case CSSPropertyWebkitBackgroundClip:
     1599    case CSSPropertyBackgroundClip:
     1600    case CSSPropertyWebkitBackgroundOrigin:
     1601    case CSSPropertyBackgroundOrigin:
     1602    case CSSPropertyWebkitBackgroundSize:
     1603    case CSSPropertyBackgroundSize:
    15981604    case CSSPropertyWebkitBorderImage:
    15991605    case CSSPropertyBorderImage:
     
    16031609    case CSSPropertyBorderImageRepeat:
    16041610    case CSSPropertyBorderImageWidth:
     1611    case CSSPropertyWebkitBoxShadow:
     1612    case CSSPropertyBoxShadow:
    16051613    case CSSPropertyWebkitTextDecoration:
    16061614    case CSSPropertyWebkitTextDecorationLine:
Note: See TracChangeset for help on using the changeset viewer.