From 0ad73bb9655f04afb5ad56174d8fb416cded3e4c Mon Sep 17 00:00:00 2001 From: Hans Goudey Date: Thu, 28 Apr 2022 08:39:30 -0500 Subject: Geometry Nodes: Add default attribute name to field inputs/outputs Geometry node group inputs and outputs get a new property that controls the attribute name used for that field input/output when assigning the node group to a modifier for the first time. If the default name is assigned to an input, the default "Use attribute name" is true . In order to properly detect when a node group is first assigned, the modifier now clears its properties when clearing the node group. Ref T96707 Differential Revision: https://developer.blender.org/D14761 --- release/scripts/startup/bl_ui/space_node.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'release/scripts') diff --git a/release/scripts/startup/bl_ui/space_node.py b/release/scripts/startup/bl_ui/space_node.py index cc673a8bc39..e105b07ec53 100644 --- a/release/scripts/startup/bl_ui/space_node.py +++ b/release/scripts/startup/bl_ui/space_node.py @@ -797,8 +797,10 @@ class NodeTreeInterfacePanel: active_socket.bl_socket_idname.startswith(prefix) for prefix in field_socket_prefixes ) - if in_out == 'OUT' and is_field_type: - layout.prop(active_socket, "attribute_domain") + if is_field_type: + if in_out == 'OUT': + layout.prop(active_socket, "attribute_domain") + layout.prop(active_socket, "default_attribute_name") active_socket.draw(context, layout) -- cgit v1.2.3