ElementRuleCollector should not use StyleResolver::State
https://bugs.webkit.org/show_bug.cgi?id=128247

Source/WebCore: 

Reviewed by Andreas Kling.
        
Make ElementRuleCollector more reusable.

* css/ElementRuleCollector.cpp:
(WebCore::ElementRuleCollector::collectMatchingRules):
(WebCore::ElementRuleCollector::sortAndTransferMatchedRules):
(WebCore::ElementRuleCollector::matchAuthorRules):
(WebCore::ElementRuleCollector::matchUARules):
(WebCore::ElementRuleCollector::ruleMatches):
(WebCore::ElementRuleCollector::collectMatchingRulesForList):
(WebCore::ElementRuleCollector::matchAllRules):
* css/ElementRuleCollector.h:
(WebCore::ElementRuleCollector::ElementRuleCollector):
        
    Pass the objects that are actually needed rather than the entire State.

LayoutTests: 

Reviewed by Andreas Kling.

* platform/mac/fast/parser/xhtml-alternate-entities-expected.png:
* platform/mac/fast/parser/xhtml-alternate-entities-expected.txt: This is a progression.



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@163475 268f45cc-cd09-0410-ab3c-d52691b4dbfc
7 files changed