summaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2014-08-06 13:51:54 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-08-06 06:21:24 -0700
commit71bed5022c52cf658ccfe4251460f2b94d68218a (patch)
treed2e044eb4367f4f46c5845b4c577a9a25dfdec8a /qt-ui
parent9d801c663f41589b37b386920cff0a823653e898 (diff)
downloadsubsurface-71bed5022c52cf658ccfe4251460f2b94d68218a.tar.gz
Don't zoom the profile when the left button is pressed
This prevents zooming out to more than max in the planner. Using a Mac MagicMouse it happens at times that the finger slides on the mouse while dragging a waypoint which can result in zooming out further than max. Fixes #695 Signed-off-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/profile/profilewidget2.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/qt-ui/profile/profilewidget2.cpp b/qt-ui/profile/profilewidget2.cpp
index 78e5eb277..a077f1619 100644
--- a/qt-ui/profile/profilewidget2.cpp
+++ b/qt-ui/profile/profilewidget2.cpp
@@ -613,6 +613,8 @@ void ProfileWidget2::wheelEvent(QWheelEvent *event)
if (currentState == EMPTY)
return;
QPoint toolTipPos = mapFromScene(toolTipItem->pos());
+ if(event->buttons() == Qt::LeftButton)
+ return;
if (event->delta() > 0 && zoomLevel < 20) {
scale(zoomFactor, zoomFactor);
zoomLevel++;