diff options
Diffstat (limited to 'source/blender/editors/space_buttons/buttons_context.c')
-rw-r--r-- | source/blender/editors/space_buttons/buttons_context.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c index 19a55c2e3cd..4c6de3ec012 100644 --- a/source/blender/editors/space_buttons/buttons_context.c +++ b/source/blender/editors/space_buttons/buttons_context.c @@ -204,6 +204,9 @@ static int buttons_context_path_object(ButsContextPath *path) if (RNA_struct_is_a(ptr->type, &RNA_Object)) { return 1; } + if (!RNA_struct_is_a(ptr->type, &RNA_ViewLayer)) { + return 0; + } ViewLayer *view_layer = ptr->data; Object *ob = (view_layer->basact) ? view_layer->basact->object : NULL; |