[CSS Grid Layout] Remove stack from grid-auto-flow syntax
authorrego@igalia.com <rego@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 2 Jan 2015 10:01:11 +0000 (10:01 +0000)
committerrego@igalia.com <rego@igalia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 2 Jan 2015 10:01:11 +0000 (10:01 +0000)
commit1641acae7f1012b6d7a201f9032c2f536cd07463
tree5ab7d15f511c433e54c11b41341c6126272269af
parentfe2d779c823835c9592522dd0d58298f0bb8c2bb
[CSS Grid Layout] Remove stack from grid-auto-flow syntax
https://bugs.webkit.org/show_bug.cgi?id=134842

Reviewed by Sergio Villar Senin.

Source/WebCore:

"stack" mode for grid-auto-flow property has been removed from the grid
layout spec. New syntax is:
  [ row | column ] || dense

Modified parsing in order to adapt it to the new syntax.

Also the current behavior relying on "stack" has been updated following
the spec. Now it won't be possible to mimic the old "none" (or "stack")
unless you specify manually the grid-placement properties.

No new tests needed, updated current tests to adapt them to the new
behavior.

* css/CSSComputedStyleDeclaration.cpp:
(WebCore::ComputedStyleExtractor::propertyValue): Adapt to new syntax.
* css/CSSParser.cpp:
(WebCore::isValidGridAutoFlowId): Remove "stack" from valid ids.
(WebCore::CSSParser::parseGridAutoFlow): Adapt to new syntax.
* css/CSSValueKeywords.in: Remove "stack".
* css/StyleResolver.cpp:
(WebCore::StyleResolver::applyProperty): Adapt to new syntax.
* rendering/RenderGrid.cpp:
(WebCore::RenderGrid::placeItemsOnGrid): Remove old "stack" code.
* rendering/style/GridResolvedPosition.cpp:
(WebCore::GridResolvedPosition::resolveGridPositionsFromStyle): If we
cannot resolve positions, we have to run the auto-placement algorithm.
* rendering/style/RenderStyle.h: Remove "stack".
* rendering/style/RenderStyleConstants.h: Ditto.

LayoutTests:

Update layout tests in order to adapt the results to the new behavior.

* fast/css-grid-layout/grid-auto-flow-get-set-expected.txt:
* fast/css-grid-layout/grid-auto-flow-get-set.html:
* fast/css-grid-layout/grid-auto-flow-update.html:
* fast/css-grid-layout/grid-item-named-grid-area-resolution.html:
* fast/css-grid-layout/grid-item-z-index-change-repaint.html:
* fast/css-grid-layout/grid-item-z-index-stacking-context.html:
* fast/css-grid-layout/grid-shorthand-get-set-expected.txt:
* fast/css-grid-layout/grid-shorthand-get-set.html:
* fast/css-grid-layout/named-grid-lines-with-named-grid-areas-dynamic-get-set.html:
* fast/css-grid-layout/named-grid-lines-with-named-grid-areas-resolution.html:
* ietestcenter/css3/grid/grid-column-001.htm:
* ietestcenter/css3/grid/grid-column-002.htm:
* ietestcenter/css3/grid/grid-column-003.htm:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@177858 268f45cc-cd09-0410-ab3c-d52691b4dbfc
23 files changed:
LayoutTests/ChangeLog
LayoutTests/fast/css-grid-layout/grid-auto-flow-get-set-expected.txt
LayoutTests/fast/css-grid-layout/grid-auto-flow-get-set.html
LayoutTests/fast/css-grid-layout/grid-auto-flow-update.html
LayoutTests/fast/css-grid-layout/grid-item-named-grid-area-resolution.html
LayoutTests/fast/css-grid-layout/grid-item-z-index-change-repaint.html
LayoutTests/fast/css-grid-layout/grid-item-z-index-stacking-context.html
LayoutTests/fast/css-grid-layout/grid-shorthand-get-set-expected.txt
LayoutTests/fast/css-grid-layout/grid-shorthand-get-set.html
LayoutTests/fast/css-grid-layout/named-grid-lines-with-named-grid-areas-dynamic-get-set.html
LayoutTests/fast/css-grid-layout/named-grid-lines-with-named-grid-areas-resolution.html
LayoutTests/ietestcenter/css3/grid/grid-column-001.htm
LayoutTests/ietestcenter/css3/grid/grid-column-002.htm
LayoutTests/ietestcenter/css3/grid/grid-column-003.htm
Source/WebCore/ChangeLog
Source/WebCore/css/CSSComputedStyleDeclaration.cpp
Source/WebCore/css/CSSParser.cpp
Source/WebCore/css/CSSValueKeywords.in
Source/WebCore/css/StyleResolver.cpp
Source/WebCore/rendering/RenderGrid.cpp
Source/WebCore/rendering/style/GridResolvedPosition.cpp
Source/WebCore/rendering/style/RenderStyle.h
Source/WebCore/rendering/style/RenderStyleConstants.h