diff options
Diffstat (limited to 'undo.h')
-rw-r--r-- | undo.h | 11 |
1 files changed, 8 insertions, 3 deletions
@@ -58,15 +58,20 @@ public: } ~UndoStack(); + inline void + push(UndoToken *token) + { + SLIST_INSERT_HEAD(&head, token, tokens); + } + void push_msg(unsigned int iMessage, uptr_t wParam = 0, sptr_t lParam = 0); template <typename Type> - void + inline void push_var(Type &variable, Type value) { - UndoToken *token = new UndoTokenVariable<Type>(variable, value); - SLIST_INSERT_HEAD(&head, token, tokens); + push(new UndoTokenVariable<Type>(variable, value)); } template <typename Type> |