[CSS Regions] In region styling (@-webkit-region) the position for CSS rules is incorrectly computed
https://bugs.webkit.org/show_bug.cgi?id=81901
Patch by Mihai Balan <mibalan@adobe.com> on 2012-03-26
Reviewed by Antti Koivisto.
Source/WebCore:
Right now CSS rules position does not take into account rules that are inside a @-webkit-region
declaration, leading to buggy behavior where rules that appear later in the document are superseded
by rules that appear earlier in the document (opposite as how things should be). The fix updates
the "global" rules counter once the rules in a @-webkit-region declaration have been added.
Tests: fast/regions/region-style-rule-position-expected.html
fast/regions/region-style-rule-position.html
* css/CSSStyleSelector.cpp:
(WebCore::CSSStyleSelector::collectMatchingRulesForList):
LayoutTests:
Ref tests for bug #81901. Testing that CSS rules position is properly computed when having multiple
@-webkit-region declarations.
* fast/regions/region-style-rule-position-expected.html: Added.
* fast/regions/region-style-rule-position.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@112099
268f45cc-cd09-0410-ab3c-
d52691b4dbfc