diff options
author | Julian Eisel <julian@blender.org> | 2021-11-23 20:32:23 +0300 |
---|---|---|
committer | Julian Eisel <julian@blender.org> | 2021-11-23 20:34:51 +0300 |
commit | 792badcfefcb92aadc16346f0dc11299a8da0ced (patch) | |
tree | 14feae7d3b2706d9a912273d804c355b66f06829 /source/blender/shader_fx | |
parent | fb4851fbbc37eaea8b46fb8d237674555f9337a0 (diff) |
Fix broken handling of constraints reordering with library overrides
Alternative to D13291 (description partially copied from there).
New drag & drop reordering code would call constraints reordering
operator with the generic context, and not the one from the panel's
layout. missing the "constraint" member which is mandatory for poll
function to properly deal with override vs. local constraints.
For this to work in a decent way, there needs to be some panel-wide
context that we can restore when executing callbacks outside of the
normal draw context. So similar to uiLayoutSetContextPointer() to set
context on a layout level, this introduces
UI_panel_context_pointer_set() for panel level context (this calls the
former for the current panel root layout as well).
Differential Revision: https://developer.blender.org/D13308
Diffstat (limited to 'source/blender/shader_fx')
-rw-r--r-- | source/blender/shader_fx/intern/FX_ui_common.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/shader_fx/intern/FX_ui_common.c b/source/blender/shader_fx/intern/FX_ui_common.c index de5bef5d8d5..b3d8b46f961 100644 --- a/source/blender/shader_fx/intern/FX_ui_common.c +++ b/source/blender/shader_fx/intern/FX_ui_common.c @@ -117,7 +117,7 @@ PointerRNA *shaderfx_panel_get_property_pointers(Panel *panel, PointerRNA *r_ob_ RNA_pointer_create(ptr->owner_id, &RNA_Object, ptr->owner_id, r_ob_ptr); } - uiLayoutSetContextPointer(panel->layout, "shaderfx", ptr); + UI_panel_context_pointer_set(panel, "shaderfx", ptr); return ptr; } |