From b7ba2dc17368d22c3d379610cd85563914fd9013 Mon Sep 17 00:00:00 2001 From: Simon De Backer Date: Sun, 14 Jun 2020 13:30:26 +0200 Subject: [PATCH] hot fix zoom and scrolling bug: was only zoom In (int QPoint::manhattanLength() const Returns the sum of the absolute values) --- sources/editor/elementview.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sources/editor/elementview.cpp b/sources/editor/elementview.cpp index b3de44dd0..9d45d9d48 100644 --- a/sources/editor/elementview.cpp +++ b/sources/editor/elementview.cpp @@ -415,11 +415,11 @@ void ElementView::wheelEvent(QWheelEvent *e) { //Zoom and scrolling if ( gestures() ) { if (e -> modifiers() & Qt::ControlModifier) - e -> angleDelta().manhattanLength() > 0 ? zoomInSlowly() : zoomOutSlowly(); + e -> angleDelta().y() > 0 ? zoomInSlowly() : zoomOutSlowly(); else QGraphicsView::wheelEvent(e); } else { - e -> angleDelta().manhattanLength() > 0 ? zoomIn(): zoomOut(); + e -> angleDelta().y() > 0 ? zoomIn(): zoomOut(); } } -- 2.26.2