#include <deletepiece.h>
Public Member Functions | |
DeletePiece (VAbstractPattern *doc, quint32 id, const VPiece &piece, QUndoCommand *parent=nullptr) | |
virtual | ~DeletePiece () |
virtual void | undo () Q_DECL_OVERRIDE |
virtual void | redo () Q_DECL_OVERRIDE |
Public Member Functions inherited from VUndoCommand | |
VUndoCommand (const QDomElement &xml, VAbstractPattern *doc, QUndoCommand *parent=nullptr) | |
virtual | ~VUndoCommand ()=default |
Private Attributes | |
QDomNode | m_parentNode |
quint32 | m_siblingId |
VPiece | m_piece |
Additional Inherited Members | |
Signals inherited from VUndoCommand | |
void | ClearScene () |
void | NeedFullParsing () |
void | NeedLiteParsing (const Document &parse) |
Protected Member Functions inherited from VUndoCommand | |
virtual void | RedoFullParsing () |
void | UndoDeleteAfterSibling (QDomNode &parentNode, const quint32 &siblingId) const |
void | IncrementReferences (const QVector< quint32 > &nodes) const |
void | DecrementReferences (const QVector< quint32 > &nodes) const |
void | IncrementReferences (const QVector< CustomSARecord > &nodes) const |
void | DecrementReferences (const QVector< CustomSARecord > &nodes) const |
void | IncrementReferences (const QVector< VPieceNode > &nodes) const |
void | DecrementReferences (const QVector< VPieceNode > &nodes) const |
QDomElement | getDestinationObject (quint32 idTool, quint32 idPoint) const |
Protected Attributes inherited from VUndoCommand | |
QDomElement | xml |
VAbstractPattern * | doc |
quint32 | nodeId |
bool | redoFlag |
Definition at line 62 of file deletepiece.h.
DeletePiece::DeletePiece | ( | VAbstractPattern * | doc, |
quint32 | id, | ||
const VPiece & | piece, | ||
QUndoCommand * | parent = nullptr |
||
) |
Definition at line 69 of file deletepiece.cpp.
References VDomDocument::AttrId, VUndoCommand::doc, VDomDocument::elementById(), VDomDocument::GetParametrUInt(), m_parentNode, m_siblingId, VUndoCommand::nodeId, NULL_ID, NULL_ID_STR, VAbstractPattern::TagPiece, and VUndoCommand::xml.
|
virtual |
Definition at line 101 of file deletepiece.cpp.
|
virtual |
Definition at line 114 of file deletepiece.cpp.
References VUndoCommand::DecrementReferences(), VUndoCommand::doc, VDomDocument::elementById(), VPiece::getAnchors(), VPiece::GetCustomSARecords(), VPiece::GetInternalPaths(), VPiecePath::GetNodes(), VPiece::GetPath(), VAbstractPattern::getTool(), m_parentNode, m_piece, VUndoCommand::NeedFullParsing(), VUndoCommand::nodeId, SCASSERT, and VAbstractPattern::TagPiece.
|
virtual |
Definition at line 105 of file deletepiece.cpp.
References m_parentNode, m_siblingId, VUndoCommand::NeedFullParsing(), and VUndoCommand::UndoDeleteAfterSibling().
|
private |
Definition at line 74 of file deletepiece.h.
Referenced by DeletePiece(), redo(), and undo().
|
private |
Definition at line 76 of file deletepiece.h.
Referenced by redo().
|
private |
Definition at line 75 of file deletepiece.h.
Referenced by DeletePiece(), and undo().