Page::pageCount() is inaccurate when we allow the first paint in App Mode
authorbdakin@apple.com <bdakin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 30 Apr 2013 19:54:20 +0000 (19:54 +0000)
committerbdakin@apple.com <bdakin@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 30 Apr 2013 19:54:20 +0000 (19:54 +0000)
https://bugs.webkit.org/show_bug.cgi?id=115442
-and corresponding-
<rdar://problem/13758445>

Reviewed by Dave Hyatt.

We should set the height here all the time, even if it is the first layout.
* rendering/RenderBlock.cpp:
(WebCore::RenderBlock::checkForPaginationLogicalHeightChange):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@149393 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/rendering/RenderBlock.cpp

index 7a22561..e5b6780 100644 (file)
@@ -1,3 +1,16 @@
+2013-04-30  Beth Dakin  <bdakin@apple.com>
+
+        Page::pageCount() is inaccurate when we allow the first paint in App Mode
+        https://bugs.webkit.org/show_bug.cgi?id=115442
+        -and corresponding-
+        <rdar://problem/13758445>
+
+        Reviewed by Dave Hyatt.
+
+        We should set the height here all the time, even if it is the first layout.
+        * rendering/RenderBlock.cpp:
+        (WebCore::RenderBlock::checkForPaginationLogicalHeightChange):
+
 2013-04-30  Andreas Kling  <akling@apple.com>
 
         Don't create StyleResolvers just to invalidate them.
index 31bfb0c..d16c3e8 100644 (file)
@@ -1517,10 +1517,11 @@ void RenderBlock::checkForPaginationLogicalHeightChange(LayoutUnit& pageLogicalH
             }
             setLogicalHeight(0);
         }
-        if (colInfo->columnHeight() != pageLogicalHeight && everHadLayout()) {
-            colInfo->setColumnHeight(pageLogicalHeight);
+
+        if (colInfo->columnHeight() != pageLogicalHeight && everHadLayout())
             pageLogicalHeightChanged = true;
-        }
+
+        colInfo->setColumnHeight(pageLogicalHeight);
         
         if (!hasSpecifiedPageLogicalHeight && !pageLogicalHeight)
             colInfo->clearForcedBreaks();