#ifndef CTRANSLATENODECOMMAND_H #define CTRANSLATENODECOMMAND_H #include #include #include #include "../INodeEditor.h" class CTranslateNodeCommand : public QUndoCommand { struct SNodeTranslate { CSceneNode *pNode; CVector3f initialPos; CVector3f newPos; }; QList mNodeList; INodeEditor *mpEditor; bool mCommandEnded; public: CTranslateNodeCommand(); CTranslateNodeCommand(INodeEditor *pEditor, const QList& nodes, const CVector3f& delta, ETransformSpace transformSpace); ~CTranslateNodeCommand(); int id() const; bool mergeWith(const QUndoCommand *other); void undo(); void redo(); static CTranslateNodeCommand* End(); }; #endif // CTRANSLATENODECOMMAND_H