diff --git a/libs/graphic/graphic.cpp b/libs/graphic/graphic.cpp index c6b2b10..83582d6 100644 --- a/libs/graphic/graphic.cpp +++ b/libs/graphic/graphic.cpp @@ -342,6 +342,7 @@ void Graphic::procGesture(QGesture * g) { QPointF dp = -pg->delta(); dp.rx() /= getScaleX(); dp.ry() /= getScaleY(); + dp.ry() = -dp.y(); selrect.translate(dp); totalUpdate(); } break; @@ -357,11 +358,7 @@ void Graphic::procGesture(QGesture * g) { } break; case Qt::TapAndHoldGesture: { QTapAndHoldGesture * pg = (QTapAndHoldGesture *)g; - if (pg->state() == Qt::GestureStarted) - QMetaObject::invokeMethod( - this, - [this]() { showMenu(); }, - Qt::QueuedConnection); + if (pg->state() == Qt::GestureStarted) QMetaObject::invokeMethod(this, [this]() { showMenu(); }, Qt::QueuedConnection); } break; default: break; }