summaryrefslogtreecommitdiff
path: root/doc/undoredoapi.txt
blob: eb73b8ccff4da55c65069ed2657cb572210353cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
undo/redo api proposal



o o o o o o o o


undoredo.create_method();
undoredo.add_do_method(node,"add_child",node_to_add);
undoredo.add_undo_method(node,"remove_child",node_to_add);
undoredo.add_add_data(node_to_add);
undoredo.commit()

undoredo.create_method();
undoredo.add_do_method(node,"remove_node",node_to_remove);
undoredo.add_undo_method(node,"add_node",node_to_remove);
undoredo.add_remove_data(node_to_remove);
undoredo.commit()


undoredo.create_property();
undoredo.add_do_set(node,"property",value);
undoredo.add_undo_set(node,"property",previous_value);
undoredo.add_remove_data(node_to_remove);
undoredo.commit()