API: Undo Blocks Functions

Hi,
Currently (v17.4), DaVinci Resolve scripts add undo points at any Set function call (and surely other functions).
This is not very handy : if I set color of 150 clips via scripts, I will have 150 undo points in undo history, so getting back to previous state will be very long.
In REAPER API, users can define their own undo block like this
This allows to have only one (or at least, a controlled amount) of undo block left by running a script. allowing scripts to be considered as single action, without spamming undo history.
This will be a very welcome addition to scripting and make it less basic IMHO, more controlled.
Thx for listening!
Currently (v17.4), DaVinci Resolve scripts add undo points at any Set function call (and surely other functions).
This is not very handy : if I set color of 150 clips via scripts, I will have 150 undo points in undo history, so getting back to previous state will be very long.
In REAPER API, users can define their own undo block like this
- Code: Select all
UndoBlock_Beging()
...
code
...
UndoBlock_End()
This allows to have only one (or at least, a controlled amount) of undo block left by running a script. allowing scripts to be considered as single action, without spamming undo history.
This will be a very welcome addition to scripting and make it less basic IMHO, more controlled.
Thx for listening!