[qet] [2092] fix regression on mousePressEvent

[ Thread Index | Date Index | More lists.tuxfamily.org/qet Archives ]


Revision: 2092
Author:   cfdev
Date:     2013-04-08 21:38:50 +0200 (Mon, 08 Apr 2013)
Log Message:
-----------
fix regression on mousePressEvent

Modified Paths:
--------------
    trunk/sources/diagramview.cpp

Modified: trunk/sources/diagramview.cpp
===================================================================
--- trunk/sources/diagramview.cpp	2013-04-08 14:39:50 UTC (rev 2091)
+++ trunk/sources/diagramview.cpp	2013-04-08 19:38:50 UTC (rev 2092)
@@ -419,6 +419,16 @@
 		switchToVisualisationModeIfNeeded(e);
 		fresh_focus_in_ = false;
 	}
+		if (isInteractive() && !scene -> isReadOnly()) {
+			if (e -> buttons() == Qt::MidButton) {
+				//paste(mapToScene(e -> pos()), QClipboard::Selection);
+			} else {
+				if (is_adding_text && e -> buttons() == Qt::LeftButton) {
+					addDiagramTextAtPos(mapToScene(e -> pos()));
+					is_adding_text = false;
+				}
+			}
+		}
 	QGraphicsView::mousePressEvent(e);
 }
 


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/