Fix: resetting/clearing the filename skipped validation
The logic to add a file extension to the filename - which runs when
editing the text was not running when resetting/clearing the value.
Resolve by calling `uiBut::func`.
Along with [0], this fixes #134101.
[0]: f2a1c8d77c
This commit is contained in:
@@ -9185,6 +9185,16 @@ void UI_context_active_but_prop_handle(bContext *C, const bool handle_undo)
|
||||
* currently this is mainly so reset defaults works for the
|
||||
* operator redo panel. */
|
||||
uiBlock *block = activebut->block;
|
||||
|
||||
/* There are various functions buttons may run on completion.
|
||||
* See #ui_apply_but_funcs_after for reference, we could even call
|
||||
* this function however it may have unforeseen consequences,
|
||||
* see replies to: !134233. */
|
||||
|
||||
/* This may be needed to validate the value, see: #134101. */
|
||||
if (activebut->func) {
|
||||
activebut->func(C, activebut->func_arg1, activebut->func_arg2);
|
||||
}
|
||||
if (block->handle_func) {
|
||||
block->handle_func(C, block->handle_func_arg, activebut->retval);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user