diff options
author | Bastien Montagne <bastien@blender.org> | 2021-01-06 20:06:11 +0300 |
---|---|---|
committer | Bastien Montagne <bastien@blender.org> | 2021-01-06 20:07:09 +0300 |
commit | 3028de9527a0a7e2772fd87fcf1abbf823698371 (patch) | |
tree | ee0498f7c5109dfde30246675009984392f2ec33 /source/blender/editors/space_image | |
parent | 5cdf279ef46fa8672d086d1f57025e31f477accc (diff) |
UndoType: Refactor: replace `use_context` boolean by a bitflag.
We will soon need more options here, sinmpler and cleaner to use a
bitflag then.
Diffstat (limited to 'source/blender/editors/space_image')
-rw-r--r-- | source/blender/editors/space_image/image_undo.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/editors/space_image/image_undo.c b/source/blender/editors/space_image/image_undo.c index 6cbebd2a959..1d5725033e0 100644 --- a/source/blender/editors/space_image/image_undo.c +++ b/source/blender/editors/space_image/image_undo.c @@ -997,8 +997,10 @@ void ED_image_undosys_type(UndoType *ut) ut->step_foreach_ID_ref = image_undosys_foreach_ID_ref; /* NOTE this is actually a confusing case, since it expects a valid context, but only in a - * specific case, see `image_undosys_step_encode` code. */ - ut->use_context_for_encode = false; + * specific case, see `image_undosys_step_encode` code. We cannot specify + * `UNDOTYPE_FLAG_NEED_CONTEXT_FOR_ENCODE` though, as it can be called with a NULL context by + * current code. */ + ut->flags = 0; ut->step_size = sizeof(ImageUndoStep); } |