Element text mover : use QPropertyUndoCommand instead of MoveElementsTextsCommand.

Remove class MoveElementsTextsCommand


git-svn-id: svn+ssh://svn.tuxfamily.org/svnroot/qet/qet/trunk@4089 bfdf4180-ca20-0410-9c96-a3a8aa849046
This commit is contained in:
blacksun
2015-08-07 19:45:00 +00:00
parent 3535ee8001
commit 65b27f411a
4 changed files with 88 additions and 191 deletions

View File

@@ -181,33 +181,6 @@ class MoveElementsCommand : public QUndoCommand {
bool first_redo;
};
class MoveElementsTextsCommand : public QUndoCommand {
// constructors, destructor
public:
MoveElementsTextsCommand(Diagram *, const QSet<ElementTextItem *> &, const QPointF &m, QUndoCommand * = 0);
virtual ~MoveElementsTextsCommand();
private:
MoveElementsTextsCommand(const MoveElementsTextsCommand &);
// methods
public:
virtual void undo();
virtual void redo();
virtual void move(const QPointF &);
// attributes
private:
/// diagram the movement takes place on.
Diagram *diagram;
/// text items to be moved
QSet<ElementTextItem *> texts_to_move;
/// applied movement
QPointF movement;
/// prevent the first call to redo()
bool first_redo;
};
/**
This command moves text items related to conductors on a particular
diagram.