Node Wrangler: Improved accuracy on Align Nodes operator #104551

Open
quackarooni wants to merge 18 commits from quackarooni/blender-addons:nw_rework_align_nodes into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
Showing only changes of commit 8e80eeef06 - Show all commits

View File

@ -2360,11 +2360,12 @@ class NWAlignNodes(Operator, NWBase):
@classmethod
def poll(cls, context):
selection = [node for node in context.selected_nodes if node.type != 'FRAME']
if len(selection) < 2:
return False
selection = (node for node in context.selected_nodes if node.type != 'FRAME')
for index, _ in enumerate(selection):
if index >= 1:
return nw_check(context)
return nw_check(context)
return False
@staticmethod
def get_midpoint(node, axis):