[CSSRegions]Change display values that allow regions
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 27 Jun 2012 18:25:16 +0000 (18:25 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 27 Jun 2012 18:25:16 +0000 (18:25 +0000)
commitb5253e2bb02ee43e043f8170b818ec7632100694
treeb5721678a0707da0c6c5c38ed24ac7e19b7ef982
parent31c9f4701e6003eab9e047adc56be37a56fb4b17
[CSSRegions]Change display values that allow regions
https://bugs.webkit.org/show_bug.cgi?id=89759

Patch by Andrei Onea <onea@adobe.com> on 2012-06-27
Reviewed by Tony Chang.

Source/WebCore:

Allow only elements with display values of block, inline-block,
table-cell, table-caption and list-item to become regions, as per
CSSRegions spec: http://dev.w3.org/csswg/css3-regions .
Also added test for checking whether regions are destroyed and/or created
when changing display value.

Test: fast/regions/region-element-display-change.html

* rendering/RenderObject.cpp:
(WebCore::RenderObject::createObject):
* rendering/style/RenderStyle.h:

LayoutTests:

Added checks for more display values, and modified results to reflect proper values that can become
regions. Also created new test for dynamically changing display values, making sure regions are
created or destroyed correctly.
* fast/regions/region-element-display-change-expected.txt: Added.
* fast/regions/region-element-display-change.html: Added.
* fast/regions/region-element-display-restriction-expected.txt:
* fast/regions/script-tests/region-element-display-change.js: Added.
(testElement):
* fast/regions/script-tests/region-element-display-restriction.js:

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@121352 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fast/regions/region-element-display-change-expected.txt [new file with mode: 0644]
LayoutTests/fast/regions/region-element-display-change.html [new file with mode: 0644]
LayoutTests/fast/regions/region-element-display-restriction-expected.txt
LayoutTests/fast/regions/script-tests/region-element-display-change.js [new file with mode: 0644]
LayoutTests/fast/regions/script-tests/region-element-display-restriction.js
Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderObject.cpp
Source/WebCore/rendering/style/RenderStyle.h