Changeset 90058 in webkit


Ignore:
Timestamp:
Jun 29, 2011 3:53:15 PM (13 years ago)
Author:
andersca@apple.com
Message:

2011-06-29 Anders Carlsson <andersca@apple.com>

Reviewed by Simon Fraser.

RenderLayer::maximumScrollPosition() is wrong
https://bugs.webkit.org/show_bug.cgi?id=62667

  • platform/ScrollableArea.h: (WebCore::ScrollableArea::isVerticalScrollerPinnedToMinimumPosition): (WebCore::ScrollableArea::isVerticalScrollerPinnedToMaximumPosition): Add these for good measure; they will be needed in an upcoming patch.
  • rendering/RenderLayer.cpp: (WebCore::RenderLayer::maximumScrollPosition): Subtract the visible content rect, including the scroll bars.
Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r90057 r90058  
     12011-06-29  Anders Carlsson  <andersca@apple.com>
     2
     3        Reviewed by Simon Fraser.
     4
     5        RenderLayer::maximumScrollPosition() is wrong
     6        https://bugs.webkit.org/show_bug.cgi?id=62667
     7
     8        * platform/ScrollableArea.h:
     9        (WebCore::ScrollableArea::isVerticalScrollerPinnedToMinimumPosition):
     10        (WebCore::ScrollableArea::isVerticalScrollerPinnedToMaximumPosition):
     11        Add these for good measure; they will be needed in an upcoming patch.
     12
     13        * rendering/RenderLayer.cpp:
     14        (WebCore::RenderLayer::maximumScrollPosition):
     15        Subtract the visible content rect, including the scroll bars.
     16
    1172011-06-29  Brent Fulgham  <bfulgham@webkit.org>
    218
  • trunk/Source/WebCore/platform/ScrollableArea.h

    r89305 r90058  
    142142    bool isHorizontalScrollerPinnedToMinimumPosition() const { return !horizontalScrollbar() || scrollPosition(horizontalScrollbar()) <= minimumScrollPosition().x(); }
    143143    bool isHorizontalScrollerPinnedToMaximumPosition() const { return !horizontalScrollbar() || scrollPosition(horizontalScrollbar()) >= maximumScrollPosition().x(); }
    144    
     144    bool isVerticalScrollerPinnedToMinimumPosition() const { return !verticalScrollbar() || scrollPosition(verticalScrollbar()) <= minimumScrollPosition().y(); }
     145    bool isVerticalScrollerPinnedToMaximumPosition() const { return !verticalScrollbar() || scrollPosition(verticalScrollbar()) >= maximumScrollPosition().y(); }
     146
    145147    virtual bool shouldRubberBandInDirection(ScrollDirection) const { return true; }
    146148
  • trunk/Source/WebCore/rendering/RenderLayer.cpp

    r90030 r90058  
    16541654{
    16551655    // FIXME: m_scrollSize may not be up-to-date if m_scrollDimensionsDirty is true.
    1656     return m_scrollOrigin + m_scrollSize;
     1656    return m_scrollOrigin + m_scrollSize - visibleContentRect(true).size();
    16571657}
    16581658
Note: See TracChangeset for help on using the changeset viewer.