refactor(undo): switch oakundo to refcounted value handles, migrate consumers

- OakUndoCommand/OakUndoStack become neutral by-value handles
  {ctx, addref, release, abi_version}; a handle is a shared_ptr
  equivalent at the ABI level, internals untouched (box owns/observes
  flag; containers adopt, boxes created by factories own)
- oaknode command factories and undoable variants return/write value
  handles; timeline command classes hold value handles; task import
  take_command returns a value handle
- tests updated everywhere; suites green: oakundo 22, oaktimeline 117,
  oaktask 106, oaknode 96, oakrender 44, oakcodec 18, oakcommon 193,
  oakaudio 36
This commit is contained in:
2026-08-07 15:48:34 +08:00
parent da2ab512c6
commit 295ea1bfe5
41 changed files with 837 additions and 684 deletions
+1 -1
View File
@@ -84,7 +84,7 @@ OakNodeNode *oaknode_folder_as_node(OakNodeFolder *folder);
* @brief Create an undoable FolderAddChild command. Owned; free with
* oakundo_command_free().
*/
OakUndoCommand *oaknode_command_create_folder_add_child(
OakUndoCommand oaknode_command_create_folder_add_child(
OakNodeFolder *folder, OakNodeNode *child);
/**