mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2025-12-17 20:50:34 +01:00
Remove the class element text item.
git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@5276 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
@@ -20,7 +20,6 @@
|
||||
#include "qetgraphicsitem/conductor.h"
|
||||
#include "qetgraphicsitem/conductortextitem.h"
|
||||
#include "diagram.h"
|
||||
#include "qetgraphicsitem/elementtextitem.h"
|
||||
#include "qetgraphicsitem/independenttextitem.h"
|
||||
#include "qgimanager.h"
|
||||
#include "diagram.h"
|
||||
@@ -100,23 +99,7 @@ void PasteDiagramCommand::redo()
|
||||
{
|
||||
//make new uuid, because old uuid are the uuid of the copied element
|
||||
e -> newUuid();
|
||||
|
||||
//Reset the text of report element
|
||||
if (e -> linkType() & Element::AllReport)
|
||||
{
|
||||
|
||||
//Befor commit 3559 there isn't text field tagged label,
|
||||
//so if not found we take the first text field
|
||||
if (ElementTextItem *eti = e->taggedText("label"))
|
||||
eti->setPlainText("/");
|
||||
else if (e->texts().size())
|
||||
e->texts().first()->setPlainText("/");
|
||||
|
||||
if (ElementTextItem *eti = e->taggedText("function"))
|
||||
eti->setPlainText("_");
|
||||
if (ElementTextItem *eti = e->taggedText("tension-protocol"))
|
||||
eti->setPlainText("_");
|
||||
}
|
||||
|
||||
if (settings.value("diagramcommands/save-label", true).toBool())
|
||||
{
|
||||
//Reset the information about the label, the comment and location
|
||||
@@ -125,10 +108,6 @@ void PasteDiagramCommand::redo()
|
||||
e -> rElementInformations().addValue("comment", "");
|
||||
e -> rElementInformations().addValue("location", "");
|
||||
|
||||
//Reset the text field tagged "label
|
||||
if (ElementTextItem *eti = e ->taggedText("label"))
|
||||
eti -> setPlainText("_");
|
||||
|
||||
//Reset the text of conductors
|
||||
const QList <Conductor *> conductors_list = content.m_conductors_to_move.toList();
|
||||
for (Conductor *c : conductors_list)
|
||||
@@ -138,11 +117,6 @@ void PasteDiagramCommand::redo()
|
||||
c -> setProperties(cp);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
//We call update label, notably to setup the connection required by the formula of the element
|
||||
e->updateLabel();
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user