| Index: third_party/WebKit/Source/core/dom/Element.cpp
|
| diff --git a/third_party/WebKit/Source/core/dom/Element.cpp b/third_party/WebKit/Source/core/dom/Element.cpp
|
| index c629e44e6990fabdeb60bb1f746c2c3e3b8dcffc..67e29c95e205616ad139015f196de9e2d76be911 100644
|
| --- a/third_party/WebKit/Source/core/dom/Element.cpp
|
| +++ b/third_party/WebKit/Source/core/dom/Element.cpp
|
| @@ -1771,13 +1771,10 @@ StyleRecalcChange Element::recalcOwnStyle(StyleRecalcChange change)
|
| }
|
|
|
| if (localChange == Reattach) {
|
| - AttachContext reattachContext;
|
| - reattachContext.resolvedStyle = newStyle.get();
|
| - bool layoutObjectWillChange = needsAttach() || layoutObject();
|
| - reattach(reattachContext);
|
| - if (layoutObjectWillChange || layoutObject())
|
| - return Reattach;
|
| - return ReattachNoLayoutObject;
|
| + // TODO(nainar): Remove the style parameter being passed into buildOwnLayout().
|
| + // ComputedStyle will now be stored on Node and accessed in buildOwnLayout()
|
| + // using mutableComputedStyle().
|
| + return buildOwnLayout(*newStyle);
|
| }
|
|
|
| DCHECK(oldStyle);
|
| @@ -1816,6 +1813,17 @@ StyleRecalcChange Element::recalcOwnStyle(StyleRecalcChange change)
|
| return localChange;
|
| }
|
|
|
| +StyleRecalcChange Element::buildOwnLayout(ComputedStyle& newStyle)
|
| +{
|
| + AttachContext reattachContext;
|
| + reattachContext.resolvedStyle = &newStyle;
|
| + bool layoutObjectWillChange = needsAttach() || layoutObject();
|
| + reattach(reattachContext);
|
| + if (layoutObjectWillChange || layoutObject())
|
| + return Reattach;
|
| + return ReattachNoLayoutObject;
|
| +}
|
| +
|
| void Element::updateCallbackSelectors(const ComputedStyle* oldStyle, const ComputedStyle* newStyle)
|
| {
|
| Vector<String> emptyVector;
|
|
|