Ignore:
Timestamp:
Dec 9, 2013, 11:45:21 AM (12 years ago)
Author:
commit-queue@webkit.org
Message:

Fix handling of 'inherit' and 'initial' for grid lines.
https://bugs.webkit.org/show_bug.cgi?id=125223

Patch by Peter Molnar <pmolnar.u-szeged@partner.samsung.com> on 2013-12-09
Reviewed by Darin Adler.

'initial' and 'inherit' are always allowed values for CSS properties.
As the CSSParser handles them automatically, those 2 values were never
taken care of in StyleResolver, leading to crashes.

Source/WebCore:

Added tests cases for 'inherit' and 'initial' to the following tests:

fast/css-grid-layout/grid-item-column-row-get-set.html
fast/css-grid-layout/grid-item-end-after-get-set.html
fast/css-grid-layout/grid-item-start-before-get-set.html

Patch backported from Blink: https://src.chromium.org/viewvc/blink?revision=149257&view=revision

  • css/StyleResolver.cpp:

(WebCore::StyleResolver::applyProperty):

  • rendering/style/RenderStyle.h:
  • rendering/style/StyleGridItemData.cpp:

(WebCore::StyleGridItemData::StyleGridItemData):

LayoutTests:

Patch backported from Blink: https://src.chromium.org/viewvc/blink?revision=149257&view=revision

  • fast/css-grid-layout/grid-item-column-row-get-set-expected.txt:
  • fast/css-grid-layout/grid-item-column-row-get-set.html:
  • fast/css-grid-layout/grid-item-end-after-get-set-expected.txt:
  • fast/css-grid-layout/grid-item-end-after-get-set.html:
  • fast/css-grid-layout/grid-item-start-before-get-set-expected.txt:
  • fast/css-grid-layout/grid-item-start-before-get-set.html:
  • fast/css-grid-layout/resources/grid-item-column-row-parsing-utils.js:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/rendering/style/StyleGridItemData.cpp

    r153746 r160322  
    3636
    3737StyleGridItemData::StyleGridItemData()
    38     : m_gridColumnStart(RenderStyle::initialGridPosition())
    39     , m_gridColumnEnd(RenderStyle::initialGridPosition())
    40     , m_gridRowStart(RenderStyle::initialGridPosition())
    41     , m_gridRowEnd(RenderStyle::initialGridPosition())
     38    : m_gridColumnStart(RenderStyle::initialGridItemColumnStart())
     39    , m_gridColumnEnd(RenderStyle::initialGridItemColumnEnd())
     40    , m_gridRowStart(RenderStyle::initialGridItemRowStart())
     41    , m_gridRowEnd(RenderStyle::initialGridItemRowEnd())
    4242{
    4343}
Note: See TracChangeset for help on using the changeset viewer.