Commit d551501d authored by Rune Lillesveen's avatar Rune Lillesveen Committed by Commit Bot

Remove style sharing workaround from StyleInvalidator.

Style sharing is no longer present in the codebase, so the SetStyle /
LocalStyleChange should no longer be necessary here.

Bug: 721517

Change-Id: I0437f3c3c3188101299b053d81b36a7542baf610
Reviewed-on: https://chromium-review.googlesource.com/625880Reviewed-by: default avatarEric Willigers <ericwilligers@chromium.org>
Reviewed-by: default avatarnainar <nainar@chromium.org>
Commit-Queue: Rune Lillesveen <rune@opera.com>
Cr-Commit-Position: refs/heads/master@{#496597}
parent bd7d7ee4
...@@ -401,18 +401,6 @@ bool StyleInvalidator::Invalidate(Element& element, ...@@ -401,18 +401,6 @@ bool StyleInvalidator::Invalidate(Element& element,
element.SetNeedsStyleRecalc(kLocalStyleChange, element.SetNeedsStyleRecalc(kLocalStyleChange,
StyleChangeReasonForTracing::Create( StyleChangeReasonForTracing::Create(
StyleChangeReason::kStyleInvalidator)); StyleChangeReason::kStyleInvalidator));
} else if (recursion_data.HasInvalidationSets() &&
some_children_need_style_recalc) {
// Clone the ComputedStyle in order to preserve correct style sharing, if
// possible. Otherwise recalc style.
if (LayoutObject* layout_object = element.GetLayoutObject()) {
layout_object->SetStyleInternal(
ComputedStyle::Clone(layout_object->StyleRef()));
} else {
element.SetNeedsStyleRecalc(kLocalStyleChange,
StyleChangeReasonForTracing::Create(
StyleChangeReason::kStyleInvalidator));
}
} }
if (recursion_data.InsertionPointCrossing() && element.IsV0InsertionPoint()) if (recursion_data.InsertionPointCrossing() && element.IsV0InsertionPoint())
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment