| Index: Source/core/rendering/RenderLayer.cpp
|
| diff --git a/Source/core/rendering/RenderLayer.cpp b/Source/core/rendering/RenderLayer.cpp
|
| index cb4710c8df9f4617f79c239035241f159278ea7c..3a42657eadf36e750eefed35eeaed4e86518c6cf 100644
|
| --- a/Source/core/rendering/RenderLayer.cpp
|
| +++ b/Source/core/rendering/RenderLayer.cpp
|
| @@ -2579,8 +2579,13 @@ IntPoint RenderLayer::minimumScrollPosition() const
|
|
|
| IntPoint RenderLayer::maximumScrollPosition() const
|
| {
|
| - // FIXME: m_scrollSize may not be up-to-date if m_scrollDimensionsDirty is true.
|
| - return -scrollOrigin() + roundedIntSize(m_scrollSize) - visibleContentRect(IncludeScrollbars).size();
|
| + RenderBox* box = renderBox();
|
| + if (!box)
|
| + return -scrollOrigin();
|
| +
|
| + LayoutRect overflowRect(box->layoutOverflowRect());
|
| + box->flipForWritingMode(overflowRect);
|
| + return -scrollOrigin() + enclosingIntRect(overflowRect).size() - enclosingIntRect(box->clientBoxRect()).size();
|
| }
|
|
|
| IntRect RenderLayer::visibleContentRect(VisibleContentRectIncludesScrollbars scrollbarInclusion) const
|
|
|