Wrong sign is paning code

This commit is contained in:
2016-07-30 14:55:06 +02:00
parent 6debf6d419
commit 5881dfeef5
+2 -2
View File
@@ -29,8 +29,8 @@ void ImageScrollArea::keyReleaseEvent(QKeyEvent *event)
void ImageScrollArea::mouseMoveEvent(QMouseEvent *event)
{
QPoint delta = m_lastPos - event->pos();
horizontalScrollBar()->setValue(horizontalScrollBar()->value() - delta.x());
verticalScrollBar()->setValue(verticalScrollBar()->value() - delta.y());
horizontalScrollBar()->setValue(horizontalScrollBar()->value() + delta.x());
verticalScrollBar()->setValue(verticalScrollBar()->value() + delta.y());
m_lastPos = event->pos();
}