Title: [156188] trunk/Source/WebCore
Revision
156188
Author
[email protected]
Date
2013-09-20 12:28:08 -0700 (Fri, 20 Sep 2013)

Log Message

Remove SelectorChecker's CrossesBoundary boundary mode
https://bugs.webkit.org/show_bug.cgi?id=121653

Reviewed by Antti Koivisto.

This mode is an ancient vestige of shadow dom.

* css/SelectorChecker.cpp:
(WebCore::SelectorChecker::match):
(WebCore::SelectorChecker::checkOne):
* css/SelectorChecker.h:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (156187 => 156188)


--- trunk/Source/WebCore/ChangeLog	2013-09-20 19:27:04 UTC (rev 156187)
+++ trunk/Source/WebCore/ChangeLog	2013-09-20 19:28:08 UTC (rev 156188)
@@ -1,5 +1,19 @@
 2013-09-20  Benjamin Poulain  <[email protected]>
 
+        Remove SelectorChecker's CrossesBoundary boundary mode
+        https://bugs.webkit.org/show_bug.cgi?id=121653
+
+        Reviewed by Antti Koivisto.
+
+        This mode is an ancient vestige of shadow dom.
+
+        * css/SelectorChecker.cpp:
+        (WebCore::SelectorChecker::match):
+        (WebCore::SelectorChecker::checkOne):
+        * css/SelectorChecker.h:
+
+2013-09-20  Benjamin Poulain  <[email protected]>
+
         Move the SharingRules mode outside of SelectorChecker
         https://bugs.webkit.org/show_bug.cgi?id=121652
 

Modified: trunk/Source/WebCore/css/SelectorChecker.cpp (156187 => 156188)


--- trunk/Source/WebCore/css/SelectorChecker.cpp	2013-09-20 19:27:04 UTC (rev 156187)
+++ trunk/Source/WebCore/css/SelectorChecker.cpp	2013-09-20 19:28:08 UTC (rev 156188)
@@ -181,13 +181,8 @@
 
     // Prepare next selector
     const CSSSelector* historySelector = context.selector->tagHistory();
-    if (!historySelector) {
-        if (context.behaviorAtBoundary == CrossesBoundary) {
-            ASSERT(context.scope);
-            return context.scope->contains(context.element) ? SelectorMatches : SelectorFailsLocally;
-        }
+    if (!historySelector)
         return SelectorMatches;
-    }
 
     SelectorCheckingContext nextContext(context);
     nextContext.selector = historySelector;
@@ -760,7 +755,7 @@
 
         case CSSSelector::PseudoScope:
             {
-                const Node* contextualReferenceNode = !context.scope || context.behaviorAtBoundary == CrossesBoundary ? element->document().documentElement() : context.scope;
+                const Node* contextualReferenceNode = !context.scope ? element->document().documentElement() : context.scope;
                 if (element == contextualReferenceNode)
                     return true;
                 break;

Modified: trunk/Source/WebCore/css/SelectorChecker.h (156187 => 156188)


--- trunk/Source/WebCore/css/SelectorChecker.h	2013-09-20 19:27:04 UTC (rev 156187)
+++ trunk/Source/WebCore/css/SelectorChecker.h	2013-09-20 19:28:08 UTC (rev 156188)
@@ -47,7 +47,7 @@
     enum Match { SelectorMatches, SelectorFailsLocally, SelectorFailsAllSiblings, SelectorFailsCompletely };
     enum VisitedMatchType { VisitedMatchDisabled, VisitedMatchEnabled };
     enum Mode { ResolvingStyle = 0, CollectingRules, QueryingRules, SharingRules };
-    enum BehaviorAtBoundary { DoesNotCrossBoundary, CrossesBoundary, StaysWithinTreeScope };
+    enum BehaviorAtBoundary { DoesNotCrossBoundary, StaysWithinTreeScope };
 
     SelectorChecker(Document&, Mode);
 
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to