Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2318)

Issue 334263020: Refactor SelectorChecker::BehaviorAtBoundary (Closed)

Created:
6 years, 6 months ago by kochi
Modified:
6 years, 5 months ago
Reviewers:
esprehn, tasak
CC:
esprehn, darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, blink-reviews-dom_chromium.org, dglazkov+blink, eae+blinkwatch, ed+blinkwatch_opera.com, hayato, rwlbuis, rune+blink, sof
Project:
blink
Visibility:
Public.

Description

Refactor SelectorChecker::BehaviorAtBoundary As of Blink r176304, SelectorCheckingContext::scope for styles in shadow tree changed from its shadow host to shadow root. Thus the subtlety of scoping difference between TreeScope and SelectorCheckingContext::scope is gone, and code for handling the difference can be cleaned up. This made possible by dropping support for <style scoped>, which introduced the complexity at r175993. With this change no functional difference is expected, thus all layout tests should pass. - Convert SelectorChecker::parentElement(context) to static helper function. - Convert SelectorChecker::scopeContainsLastMatchedElement() to static helper function. - s/{b,B}ehaviorAtBounary/{c,C}ontextFlags/g - Removed the 2nd parameter in rulesApplicableInCurrentTreeScope() - Removed the 2nd argument for isHostInItsShadowTree() - Removed StaysWithinTreeScope - Removed DoesNotCrossBoundary - Removed ScopeIsShadowRoot. - Removed BoundaryBehaviorMask - Removed ScopeIsShadowHostInPseudoHostParameter - Introduced DefaultBehavior (to be removed, though) BUG=none TEST=pass all layout tests. Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=177183

Patch Set 1 #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+51 lines, -92 lines) Patch
M Source/core/css/ElementRuleCollector.h View 2 chunks +5 lines, -5 lines 0 comments Download
M Source/core/css/ElementRuleCollector.cpp View 8 chunks +17 lines, -17 lines 0 comments Download
M Source/core/css/SelectorChecker.h View 6 chunks +9 lines, -16 lines 0 comments Download
M Source/core/css/SelectorChecker.cpp View 9 chunks +16 lines, -41 lines 4 comments Download
M Source/core/css/TreeBoundaryCrossingRules.cpp View 1 chunk +1 line, -6 lines 0 comments Download
M Source/core/css/resolver/ScopedStyleResolver.cpp View 1 chunk +3 lines, -6 lines 0 comments Download
M Source/core/dom/SelectorQuery.cpp View 1 chunk +0 lines, -1 line 0 comments Download

Messages

Total messages: 8 (0 generated)
kochi
Hi Takashi, There still remain 2 flags in BehaviorAtBoundary, but the code should be much ...
6 years, 6 months ago (2014-06-26 09:12:46 UTC) #1
tasak
lgtm
6 years, 6 months ago (2014-06-27 03:35:50 UTC) #2
kochi
On 2014/06/27 03:35:50, tasak wrote: > lgtm Thanks, as we discussed offline, I intend to ...
6 years, 6 months ago (2014-06-27 03:46:21 UTC) #3
esprehn
This lgtm, but can you explain why it was correct to remove all of those ...
6 years, 6 months ago (2014-06-27 08:05:51 UTC) #4
kochi
Thanks Elliott for the review. Updated the description and replied to your comments inline. https://codereview.chromium.org/334263020/diff/1/Source/core/css/SelectorChecker.cpp ...
6 years, 5 months ago (2014-06-30 02:44:06 UTC) #5
kochi
The CQ bit was checked by kochi@chromium.org
6 years, 5 months ago (2014-06-30 02:44:12 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/kochi@chromium.org/334263020/1
6 years, 5 months ago (2014-06-30 02:44:23 UTC) #7
commit-bot: I haz the power
6 years, 5 months ago (2014-06-30 03:37:26 UTC) #8
Message was sent while issue was closed.
Change committed as 177183

Powered by Google App Engine
This is Rietveld 408576698