]> git.lizzy.rs Git - nothing.git/blobdiff - src/game/level/level_editor/undo_history.c
Remove TODO(#956)
[nothing.git] / src / game / level / level_editor / undo_history.c
index 05f703ca469625308a9f0f378aace28d8644af56..5aba786d37b5593df6a3f43c11f4636255c7fb99 100644 (file)
 
 typedef struct {
     RevertAction revert;
-    void *layer;
 } Action;
 
 void undo_history_push(UndoHistory *undo_history,
-                       void *layer,
                        RevertAction revert,
                        void *context_data,
                        size_t context_data_size)
@@ -23,7 +21,6 @@ void undo_history_push(UndoHistory *undo_history,
 
     Action action = {
         .revert = revert,
-        .layer = layer
     };
 
     stack_push(&undo_history->actions, context_data, context_data_size);
@@ -41,7 +38,7 @@ void undo_history_pop(UndoHistory *undo_history)
         size_t context_size = stack_top_size(&undo_history->actions);
         void *context = stack_top_element(&undo_history->actions);
 
-        action.revert(action.layer, context, context_size);
+        action.revert(context, context_size);
         stack_pop(&undo_history->actions);
     }
 }