Index: Source/core/frame/FrameView.cpp |
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp |
index b7540d9fe937adc128d4c3ed672d330b822a5258..736095b2a23daa5bebcceb053c05155809c49b30 100644 |
--- a/Source/core/frame/FrameView.cpp |
+++ b/Source/core/frame/FrameView.cpp |
@@ -806,6 +806,9 @@ void FrameView::layout(bool allowSubtree) |
// Every scroll that happens during layout is programmatic. |
TemporaryChange<bool> changeInProgrammaticScroll(m_inProgrammaticScroll, true); |
+ if (m_autoSizeInfo) |
+ m_autoSizeInfo->autoSizeIfNeeded(); |
+ |
m_hasPendingLayout = false; |
DocumentLifecycle::Scope lifecycleScope(lifecycle(), DocumentLifecycle::LayoutClean); |
@@ -856,8 +859,6 @@ void FrameView::layout(bool allowSubtree) |
} |
} |
updateCounters(); |
- if (m_autoSizeInfo) |
- m_autoSizeInfo->autoSizeIfNeeded(); |
ScrollbarMode hMode; |
ScrollbarMode vMode; |