src/ui/canvas.cpp

changeset 121
000781318c36
parent 120
8c9fff699241
child 128
7c834fe36b25
--- a/src/ui/canvas.cpp	Wed Jul 28 13:22:51 2021 +0300
+++ b/src/ui/canvas.cpp	Fri Jul 30 01:28:39 2021 +0300
@@ -86,8 +86,9 @@
 		this->updateGridMatrix();
 		this->update();
 	}
-	Q_EMIT this->mouseMove(this);
+	Q_EMIT this->mouseMove(this, event);
 	PartRenderer::mouseMoveEvent(event);
+	this->update();
 }
 
 void Canvas::mousePressEvent(QMouseEvent* event)
@@ -101,9 +102,10 @@
 {
 	if (this->totalMouseMove < (2.0 / sqrt(2)) * 5.0)
 	{
-		Q_EMIT this->mouseClick(this);
+		Q_EMIT this->mouseClick(this, event);
 	}
 	PartRenderer::mouseReleaseEvent(event);
+	this->update();
 }
 
 void Canvas::initializeGL()

mercurial