X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/4e82b359897def33c90cd5465cda3ed10b5aa01a..b1c9b5126d:/src/dolphinviewautoscroller.h diff --git a/src/dolphinviewautoscroller.h b/src/dolphinviewautoscroller.h index 177c6ee0f..3827b2326 100644 --- a/src/dolphinviewautoscroller.h +++ b/src/dolphinviewautoscroller.h @@ -38,27 +38,28 @@ class DolphinViewAutoScroller : public QObject public: DolphinViewAutoScroller(QAbstractItemView* parent); virtual ~DolphinViewAutoScroller(); - + bool isActive() const; + protected: virtual bool eventFilter(QObject* watched, QEvent* event); private slots: void scrollViewport(); - void scrollToCurrentIndex(); - + private: void triggerAutoScroll(); void stopAutoScroll(); - + /** - * Calculates the scroll increment m_scrollInc dependent from + * Calculates the scroll increment dependent from * the cursor position \a cursorPos and the range 0 - \a rangeSize - 1. */ - void calculateScrollIncrement(int cursorPos, int rangeSize); - + int calculateScrollIncrement(int cursorPos, int rangeSize) const; + private: bool m_rubberBandSelection; - int m_scrollInc; + int m_horizontalScrollInc; + int m_verticalScrollInc; QAbstractItemView* m_itemView; QTimer* m_timer; };