[Bf-blender-cvs] [01a4d386066] master: Fix: Group input and output always show in node add menu
Miguel Porces
noreply at git.blender.org
Tue Sep 20 19:10:50 CEST 2022
Commit: 01a4d386066f6b262ec71e081764016a27243263
Author: Miguel Porces
Date: Tue Sep 20 12:07:59 2022 -0500
Branches: master
https://developer.blender.org/rB01a4d386066f6b262ec71e081764016a27243263
Fix: Group input and output always show in node add menu
In D10241, both NodeItems for NodeGroupInput and NodeGroupOutput in the
were moved from their categories into the 'node_group_items' generator.
As the NodeItem.poll() is called by the NodeCategory class and not by
the NodeItem class, the poll functions associated with those NodeItems
were never called. This should correct that.
Differential Revision: https://developer.blender.org/D16013
===================================================================
M release/scripts/startup/nodeitems_builtins.py
===================================================================
diff --git a/release/scripts/startup/nodeitems_builtins.py b/release/scripts/startup/nodeitems_builtins.py
index 9c0635d7bd4..d2188515e16 100644
--- a/release/scripts/startup/nodeitems_builtins.py
+++ b/release/scripts/startup/nodeitems_builtins.py
@@ -261,8 +261,9 @@ def node_group_items(context):
yield NodeItemCustom(draw=group_tools_draw)
- yield NodeItem("NodeGroupInput", poll=group_input_output_item_poll)
- yield NodeItem("NodeGroupOutput", poll=group_input_output_item_poll)
+ if group_input_output_item_poll(context):
+ yield NodeItem("NodeGroupInput")
+ yield NodeItem("NodeGroupOutput")
ntree = space.edit_tree
if not ntree:
More information about the Bf-blender-cvs
mailing list