From fe79935f0021755ba133020a3414f6c29b46e9aa Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Mon, 26 Apr 2021 22:16:12 -0500 Subject: Fix T87401: Drop-down can apply the wrong modifier The trouble was that there was a context pointer "modifier" in the property editor context that returned the active modifier. But the "modifier" variable was already used in many places, for pointers that are *not* equivalent to the active modifier. The context pointer for the active modifier was unecessary anyway. If we need to access a context pointer for the active modifier in the property editor then we can add it. Until then it only adds confusion. --- source/blender/editors/space_buttons/buttons_context.c | 11 ----------- 1 file changed, 11 deletions(-) (limited to 'source/blender/editors/space_buttons') diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c index c42e2531f25..1699e704a4d 100644 --- a/source/blender/editors/space_buttons/buttons_context.c +++ b/source/blender/editors/space_buttons/buttons_context.c @@ -981,17 +981,6 @@ int /*eContextResult*/ buttons_context(const bContext *C, return CTX_RESULT_OK; } - if (CTX_data_equals(member, "modifier")) { - PointerRNA *ptr = get_pointer_type(path, &RNA_Modifier); - - if (ptr != NULL && !RNA_pointer_is_null(ptr)) { - Object *ob = (Object *)ptr->owner_id; - ModifierData *md = ptr->data; - CTX_data_pointer_set(result, &ob->id, &RNA_Modifier, md); - return CTX_RESULT_OK; - } - return CTX_RESULT_NO_DATA; - } if (CTX_data_equals(member, "texture_user")) { ButsContextTexture *ct = sbuts->texuser; -- cgit v1.2.3