summaryrefslogtreecommitdiff
path: root/tikzit/src/gui/undocommands.h
diff options
context:
space:
mode:
Diffstat (limited to 'tikzit/src/gui/undocommands.h')
-rw-r--r--tikzit/src/gui/undocommands.h22
1 files changed, 22 insertions, 0 deletions
diff --git a/tikzit/src/gui/undocommands.h b/tikzit/src/gui/undocommands.h
new file mode 100644
index 0000000..bbdf6c3
--- /dev/null
+++ b/tikzit/src/gui/undocommands.h
@@ -0,0 +1,22 @@
+/**
+ * These classes store the data required to undo/redo a single UI action.
+ */
+
+#ifndef UNDOCOMMANDS_H
+#define UNDOCOMMANDS_H
+
+#include "tikzscene.h"
+
+#include <QUndoCommand>
+
+class MoveCommand : public QUndoCommand
+{
+public:
+ explicit MoveCommand(TikzScene *scene, QUndoCommand *parent = 0);
+ void undo() override;
+ void redo() override;
+private:
+ TikzScene *_scene;
+};
+
+#endif // UNDOCOMMANDS_H