summaryrefslogtreecommitdiffstats
path: root/qt-ui/diveplanner.cpp
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2015-01-19 18:15:03 +1200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-01-19 18:15:03 +1200
commitde9acbd30d5af81d5774a92e4734e04cdb3084b1 (patch)
treed8610aba6b152832d6a2b894584fbb77f546db2c /qt-ui/diveplanner.cpp
parent93058f28ea886b06a012daeba49c3c9eb95a587d (diff)
parentf448bfd574bb9aa4593b43392131174dc489a4b0 (diff)
downloadsubsurface-de9acbd30d5af81d5774a92e4734e04cdb3084b1.tar.gz
Merge branch 'latestmaster'
Diffstat (limited to 'qt-ui/diveplanner.cpp')
-rw-r--r--qt-ui/diveplanner.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp
index 44ca6baf5..2ee168413 100644
--- a/qt-ui/diveplanner.cpp
+++ b/qt-ui/diveplanner.cpp
@@ -181,6 +181,7 @@ DiveHandler::DiveHandler() : QGraphicsEllipseItem()
setFlags(ItemIgnoresTransformations | ItemIsSelectable | ItemIsMovable | ItemSendsGeometryChanges);
setBrush(Qt::white);
setZValue(2);
+ t.start();
}
int DiveHandler::parentIndex()
@@ -225,9 +226,14 @@ void DiveHandler::changeGas()
void DiveHandler::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
{
+ if (t.elapsed() < 40)
+ return;
+ t.start();
+
ProfileWidget2 *view = qobject_cast<ProfileWidget2*>(scene()->views().first());
if(view->isPointOutOfBoundaries(event->scenePos()))
return;
+
QGraphicsEllipseItem::mouseMoveEvent(event);
emit moved();
}