Now we only use 'undo' or 'redo' in function names when the direction is
clear (and we assert about it). Otherwise, use 'load' instead.
When passing an undo step to BKE functions, consider calling code has
done its work and is actually passing the target step (i.e. the final
step intended to be loaded), instead of assuming we have to load the
step before/after it.
Also deduplicate and simplify a lot of core undo code in BKE, now
BKE_undosys_step_load_data_ex is the only place where all the complex
logic of undo/redo loop (to handle several steps in a row) is placed. We also
only use a single loop there, instead of the two existing ones in
previous code.
Note that here we consider that when we are loading the current active
step, we are undoing. This makes sense in that doing so may undo
some changes (ideally it should never do so), but should never, ever
redo anything.
BKE_undosys_step_load_from_index also gets heavily simplified, it's
not basically a shallow wrapper around
BKE_undosys_step_load_from_index.
And some general update of variable names, commenting, etc.
Part of T83806.
NOTE: We have to move eUndoStepDir to BKE_undo_system.c, so that we can get rid of 'magical' values everywhere, including in all the lower-level implementations of actual undo types. Will do in a separate cleanup commit though.