diff options
-rw-r--r-- | source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c b/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c index ede0f7c96ea..ec8e012b1a7 100644 --- a/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c +++ b/source/blender/windowmanager/gizmo/intern/wm_gizmo_map.c @@ -945,12 +945,14 @@ void wm_gizmomap_modal_set( WM_tooltip_clear(C, win); + /* Use even if we don't have invoke, so we can setup data before an operator runs. */ + if (gz->parent_gzgroup->type->invoke_prepare) { + gz->parent_gzgroup->type->invoke_prepare(C, gz->parent_gzgroup, gz); + } + if (gz->type->invoke && (gz->type->modal || gz->custom_modal)) { - if (gz->parent_gzgroup->type->invoke_prepare) { - gz->parent_gzgroup->type->invoke_prepare(C, gz->parent_gzgroup, gz); - } const int retval = gz->type->invoke(C, gz, event); if ((retval & OPERATOR_RUNNING_MODAL) == 0) { return; |