diff options
| author | Peter Penz <[email protected]> | 2011-08-27 20:12:03 +0200 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2011-08-27 20:13:22 +0200 |
| commit | d99d5fbea76a79346761c0d8ce98a0719e5790d2 (patch) | |
| tree | 50b944a3adf3e4533003d91df16f3b19bb636412 /src/kitemviews/kitemlistcontroller.cpp | |
| parent | 4905667ada4ddd0aee3d2bb077e401a4262804b9 (diff) | |
Improve the autoscrolling for the rubberband selection
This modifications will also allow to do an autoscrolling in an
easy way for drag and drop operations (not fully implemented yet).
Diffstat (limited to 'src/kitemviews/kitemlistcontroller.cpp')
| -rw-r--r-- | src/kitemviews/kitemlistcontroller.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/kitemviews/kitemlistcontroller.cpp b/src/kitemviews/kitemlistcontroller.cpp index ddae06c17..78c0a3594 100644 --- a/src/kitemviews/kitemlistcontroller.cpp +++ b/src/kitemviews/kitemlistcontroller.cpp @@ -306,6 +306,7 @@ bool KItemListController::mousePressEvent(QGraphicsSceneMouseEvent* event, const rubberBand->setEndPosition(startPos); rubberBand->setActive(true); connect(rubberBand, SIGNAL(endPositionChanged(QPointF,QPointF)), this, SLOT(slotRubberBandChanged())); + m_view->setAutoScroll(true); } return false; @@ -365,6 +366,7 @@ bool KItemListController::mouseReleaseEvent(QGraphicsSceneMouseEvent* event, con disconnect(rubberBand, SIGNAL(endPositionChanged(QPointF,QPointF)), this, SLOT(slotRubberBandChanged())); rubberBand->setActive(false); m_oldSelection.clear(); + m_view->setAutoScroll(false); if (rubberBand->startPosition() != rubberBand->endPosition()) { clearSelection = false; |
