Index: third_party/WebKit/Source/core/style/ComputedStyle.cpp |
diff --git a/third_party/WebKit/Source/core/style/ComputedStyle.cpp b/third_party/WebKit/Source/core/style/ComputedStyle.cpp |
index a53868d5208a2a2d950d3bc3f2f1dc5cc91b81b5..ce181590e397b542416a4be2f8b245d245992bf2 100644 |
--- a/third_party/WebKit/Source/core/style/ComputedStyle.cpp |
+++ b/third_party/WebKit/Source/core/style/ComputedStyle.cpp |
@@ -542,7 +542,7 @@ StyleDifference ComputedStyle::visualInvalidationDiff( |
} |
if (!diff.needsFullLayout() && position() != EPosition::kStatic && |
- m_surround->offset != other.m_surround->offset) { |
+ !offsetEqual(other)) { |
// Optimize for the case where a positioned layer is moving but not changing |
// size. |
if (dependenceOnContentHeightHasChanged(*this, other)) |
@@ -594,8 +594,7 @@ bool ComputedStyle::scrollAnchorDisablingPropertyChanged( |
} |
if (m_surround.get() != other.m_surround.get()) { |
- if (m_surround->margin != other.m_surround->margin || |
- m_surround->offset != other.m_surround->offset || |
+ if (m_surround->margin != other.m_surround->margin || !offsetEqual(other) || |
m_surround->padding != other.m_surround->padding) |
return true; |
} |