Fix [#22088] Object's material changes (links) to other when moving an object
to an other layer WM_operator_props_popup() and subsequent block handle function redo_cb() was popping an operator undo, without having pushed one previously - this would undo one too many times when using the properties invoke popup. Fixed by adding an undo push to WM_operator_props_popup()
This commit is contained in:
@@ -1016,8 +1016,12 @@ int WM_operator_props_popup(bContext *C, wmOperator *op, wmEvent *event)
|
||||
{
|
||||
int retval= OPERATOR_CANCELLED;
|
||||
|
||||
if(op->type->exec)
|
||||
if(op->type->exec) {
|
||||
retval= op->type->exec(C, op);
|
||||
|
||||
if(op->type->flag & OPTYPE_UNDO)
|
||||
ED_undo_push_op(C, op);
|
||||
}
|
||||
|
||||
if(retval != OPERATOR_CANCELLED)
|
||||
uiPupBlock(C, wm_block_create_redo, op);
|
||||
|
||||
Reference in New Issue
Block a user