diff options
Diffstat (limited to 'Source/WebCore/platform/ScrollableArea.h')
-rw-r--r-- | Source/WebCore/platform/ScrollableArea.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/Source/WebCore/platform/ScrollableArea.h b/Source/WebCore/platform/ScrollableArea.h index f1c1308..d08de00 100644 --- a/Source/WebCore/platform/ScrollableArea.h +++ b/Source/WebCore/platform/ScrollableArea.h @@ -69,6 +69,7 @@ public: bool hasOverlayScrollbars() const; ScrollAnimator* scrollAnimator() const { return m_scrollAnimator.get(); } + const IntPoint& scrollOrigin() const { return m_scrollOrigin; } virtual int scrollSize(ScrollbarOrientation) const = 0; virtual int scrollPosition(Scrollbar*) const = 0; @@ -114,6 +115,10 @@ public: virtual IntSize overhangAmount() const { ASSERT_NOT_REACHED(); return IntSize(); } virtual IntPoint currentMousePosition() const { return IntPoint(); } virtual void didCompleteRubberBand(const IntSize&) const { ASSERT_NOT_REACHED(); } + virtual bool shouldSuspendScrollAnimations() const { return true; } + virtual void scrollbarStyleChanged() { } + + virtual void disconnectFromPage() { } private: // NOTE: Only called from the ScrollAnimator. @@ -124,6 +129,20 @@ private: bool m_constrainsScrollingToContentEdge; bool m_inLiveResize; + +protected: + // There are 8 possible combinations of writing mode and direction. Scroll origin will be non-zero in the x or y axis + // if there is any reversed direction or writing-mode. The combinations are: + // writing-mode / direction scrollOrigin.x() set scrollOrigin.y() set + // horizontal-tb / ltr NO NO + // horizontal-tb / rtl YES NO + // horizontal-bt / ltr NO YES + // horizontal-bt / rtl YES YES + // vertical-lr / ltr NO NO + // vertical-lr / rtl NO YES + // vertical-rl / ltr YES NO + // vertical-rl / rtl YES YES + IntPoint m_scrollOrigin; }; } // namespace WebCore |