don't make a loop of scrollbar updating->position updating

svn path=/trunk/KDE/kdelibs/; revision=979074
This commit is contained in:
Marco Martin 2009-06-08 21:06:23 +00:00
parent 49043d7f49
commit 75e7968ae5

View File

@ -270,8 +270,12 @@ bool ScrollWidget::eventFilter(QObject *watched, QEvent *event)
d->adjustScrollbars();
d->adjustClipping();
} else if (watched == d->widget && event->type() == QEvent::GraphicsSceneMove) {
d->horizontalScrollBar->blockSignals(true);
d->verticalScrollBar->blockSignals(true);
d->horizontalScrollBar->setValue(-d->widget->pos().x()/10);
d->verticalScrollBar->setValue(-d->widget->pos().y()/10);
d->horizontalScrollBar->blockSignals(false);
d->verticalScrollBar->blockSignals(false);
}
return false;