Title: [147462] tags/Safari-537.35.6/Source/WebCore
- Revision
- 147462
- Author
- [email protected]
- Date
- 2013-04-02 11:06:42 -0700 (Tue, 02 Apr 2013)
Log Message
Merged r147373. <rdar://problem/13202277>
Modified Paths
Diff
Modified: tags/Safari-537.35.6/Source/WebCore/ChangeLog (147461 => 147462)
--- tags/Safari-537.35.6/Source/WebCore/ChangeLog 2013-04-02 18:04:18 UTC (rev 147461)
+++ tags/Safari-537.35.6/Source/WebCore/ChangeLog 2013-04-02 18:06:42 UTC (rev 147462)
@@ -1,5 +1,27 @@
2013-04-01 Lucas Forschler <[email protected]>
+ Merge r147373
+
+ 2013-04-01 Tim Horton <[email protected]>
+
+ Autosize should use documentRect height instead of scrollHeight
+ https://bugs.webkit.org/show_bug.cgi?id=112770
+
+ Reviewed by David Levin.
+
+ Autosizing fails to compute the correct height if the root element is very
+ small but the document has significant overflow.
+
+ Also, unconditionally start laying out from the minimum height, so that the
+ documentRect can shrink below its previous height if needed.
+
+ No new tests; autosizing is not currently exposed in a testable way on Mac.
+
+ * page/FrameView.cpp:
+ (WebCore::FrameView::autoSizeIfEnabled):
+
+2013-04-01 Lucas Forschler <[email protected]>
+
Merge r147359
2013-04-01 Alexey Proskuryakov <[email protected]>
Modified: tags/Safari-537.35.6/Source/WebCore/page/FrameView.cpp (147461 => 147462)
--- tags/Safari-537.35.6/Source/WebCore/page/FrameView.cpp 2013-04-02 18:04:18 UTC (rev 147461)
+++ tags/Safari-537.35.6/Source/WebCore/page/FrameView.cpp 2013-04-02 18:06:42 UTC (rev 147462)
@@ -2770,15 +2770,9 @@
if (!documentView || !documentElement)
return;
- RenderBox* documentRenderBox = documentElement->renderBox();
- if (!documentRenderBox)
- return;
+ // Start from the minimum height and allow it to grow.
+ resize(frameRect().width(), m_minAutoSize.height());
- // If this is the first time we run autosize, start from small height and
- // allow it to grow.
- if (!m_didRunAutosize)
- resize(frameRect().width(), m_minAutoSize.height());
-
IntSize size = frameRect().size();
// Do the resizing twice. The first time is basically a rough calculation using the preferred width
@@ -2787,7 +2781,7 @@
// Update various sizes including contentsSize, scrollHeight, etc.
document->updateLayoutIgnorePendingStylesheets();
int width = documentView->minPreferredLogicalWidth();
- int height = documentRenderBox->scrollHeight();
+ int height = documentView->documentRect().height();
IntSize newSize(width, height);
// Check to see if a scrollbar is needed for a given dimension and
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes