[qet] [2130] minor change, revamp method applyText

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


Revision: 2130
Author:   blacksun
Date:     2013-04-26 00:32:29 +0200 (Fri, 26 Apr 2013)
Log Message:
-----------
minor change, revamp method applyText

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

Modified: trunk/sources/conductorautonumerotation.cpp
===================================================================
--- trunk/sources/conductorautonumerotation.cpp	2013-04-25 21:40:22 UTC (rev 2129)
+++ trunk/sources/conductorautonumerotation.cpp	2013-04-25 22:32:29 UTC (rev 2130)
@@ -92,14 +92,11 @@
 	if (conductor_list.empty()) {
 		//initialize the corresponding UndoCommand object
 		ChangeConductorPropertiesCommand *ccpc = new ChangeConductorPropertiesCommand (conductor_);
-		ConductorProperties cp;
-		cp = conductor_ ->properties();
-		ccpc -> setOldSettings(cp);
+		ccpc -> setOldSettings (conductor_ -> properties());
+		ConductorProperties cp = conductor_ -> properties();
 		cp.text = t;
 		ccpc -> setNewSettings(cp);
 		diagram_ -> undoStack().push(ccpc);
-		conductor_ -> setProperties(cp);
-		conductor_ -> setText(t);
 	}
 	else {
 		QSet <Conductor *> clist = conductor_list;
@@ -111,9 +108,7 @@
 			old_properties << c -> properties();
 			cp = c -> properties();
 			cp.text = t;
-			c -> setProperties(cp);
-			new_properties << c -> properties();
-			c -> setText(t);
+			new_properties << cp;
 		}
 		//initialize the corresponding UndoCommand object
 		ChangeSeveralConductorsPropertiesCommand *cscpc = new ChangeSeveralConductorsPropertiesCommand(clist);


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