Chromium Code Reviews| Index: third_party/WebKit/Source/core/dom/StyleEngine.cpp |
| diff --git a/third_party/WebKit/Source/core/dom/StyleEngine.cpp b/third_party/WebKit/Source/core/dom/StyleEngine.cpp |
| index b19e177637881117d3334b75f792be6cbc922a4a..5d5c90bfc1409ce19b9cb89e62e118b89c87c655 100644 |
| --- a/third_party/WebKit/Source/core/dom/StyleEngine.cpp |
| +++ b/third_party/WebKit/Source/core/dom/StyleEngine.cpp |
| @@ -871,7 +871,7 @@ void StyleEngine::ScheduleTypeRuleSetInvalidations( |
| } |
| void StyleEngine::InvalidateSlottedElements(HTMLSlotElement& slot) { |
| - for (auto& node : slot.GetDistributedNodes()) { |
| + for (auto& node : slot.GetDistributedNodesExcludingFallback()) { |
|
hayato
2017/05/18 06:58:25
Is this correct? Why doesn't this need to invalida
kochi
2017/05/18 07:21:49
If this is not correct, I'll file another bug.
Thi
|
| if (node->IsElementNode()) |
| node->SetNeedsStyleRecalc(kLocalStyleChange, |
| StyleChangeReasonForTracing::Create( |
| @@ -912,7 +912,8 @@ void StyleEngine::ScheduleInvalidationsForRuleSets( |
| Element* element = ElementTraversal::FirstChild(*stay_within); |
| while (element) { |
| ScheduleRuleSetInvalidationsForElement(*element, rule_sets); |
| - if (invalidate_slotted && isHTMLSlotElement(element)) |
| + if (invalidate_slotted && isHTMLSlotElement(element) && |
| + toHTMLSlotElement(element)->SupportsDistribution()) |
| InvalidateSlottedElements(toHTMLSlotElement(*element)); |
| if (element->GetStyleChangeType() < kSubtreeStyleChange) |