Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(531)

Unified Diff: third_party/WebKit/WebCore/rendering/RenderView.cpp

Issue 21184: WebKit merge 40722:40785 (part 1) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/WebCore/rendering/RenderView.cpp
===================================================================
--- third_party/WebKit/WebCore/rendering/RenderView.cpp (revision 9391)
+++ third_party/WebKit/WebCore/rendering/RenderView.cpp (working copy)
@@ -619,7 +619,7 @@
// The idea here is to take into account what object is moving the pagination point, and
// thus choose the best place to chop it.
-void RenderView::setBestTruncatedAt(int y, RenderBox* forRenderer, bool forcedBreak)
+void RenderView::setBestTruncatedAt(int y, RenderBoxModelObject* forRenderer, bool forcedBreak)
{
// Nobody else can set a page break once we have a forced break.
if (m_forcedPageBreak)
@@ -632,9 +632,10 @@
return;
}
- // prefer the widest object who tries to move the pagination point
- if (forRenderer->width() > m_truncatorWidth) {
- m_truncatorWidth = forRenderer->width();
+ // Prefer the widest object that tries to move the pagination point
+ IntRect boundingBox = forRenderer->borderBoundingBox();
+ if (boundingBox.width() > m_truncatorWidth) {
+ m_truncatorWidth = boundingBox.width();
m_bestTruncatedAt = y;
}
}
« no previous file with comments | « third_party/WebKit/WebCore/rendering/RenderView.h ('k') | third_party/WebKit/WebCore/rendering/SVGCharacterLayoutInfo.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698