ignore the scroll event if the widget is totally scrolled
svn path=/trunk/KDE/kdelibs/; revision=1035777
This commit is contained in:
parent
d7915a8dff
commit
342489ea62
@ -197,7 +197,19 @@ void KineticScrolling::wheelReleaseEvent(QGraphicsSceneWheelEvent *event)
|
||||
|
||||
int temp = -event->delta();
|
||||
|
||||
if ((event->delta() < 0 && d->canScroll(KineticScrollingPrivate::Down)) ||
|
||||
(event->delta() > 0 && d->canScroll(KineticScrollingPrivate::Up))){
|
||||
d->kinMovement.setY(kinMovement().y() + temp);
|
||||
} else if (!d->canScroll(KineticScrollingPrivate::Down) &&
|
||||
!d->canScroll(KineticScrollingPrivate::Up)) {
|
||||
if ((event->delta() < 0 && d->canScroll(KineticScrollingPrivate::Right)) ||
|
||||
(event->delta() > 0 && d->canScroll(KineticScrollingPrivate::Left))) {
|
||||
d->kinMovement.setX(kinMovement().x() + temp);
|
||||
}
|
||||
} else {
|
||||
event->ignore();
|
||||
return;
|
||||
}
|
||||
|
||||
startAnimationTimer(30);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user