Call parent __init__ as soon as possible for CtrlNode
This commit is contained in:
parent
23b4e174f0
commit
a4cecf4a22
@ -91,14 +91,15 @@ class CtrlNode(Node):
|
||||
sigStateChanged = QtCore.Signal(object)
|
||||
|
||||
def __init__(self, name, ui=None, terminals=None):
|
||||
if terminals is None:
|
||||
terminals = {'In': {'io': 'in'}, 'Out': {'io': 'out', 'bypass': 'In'}}
|
||||
Node.__init__(self, name=name, terminals=terminals)
|
||||
|
||||
if ui is None:
|
||||
if hasattr(self, 'uiTemplate'):
|
||||
ui = self.uiTemplate
|
||||
else:
|
||||
ui = []
|
||||
if terminals is None:
|
||||
terminals = {'In': {'io': 'in'}, 'Out': {'io': 'out', 'bypass': 'In'}}
|
||||
Node.__init__(self, name=name, terminals=terminals)
|
||||
|
||||
self.ui, self.stateGroup, self.ctrls = generateUi(ui)
|
||||
self.stateGroup.sigChanged.connect(self.changed)
|
||||
|
Loading…
Reference in New Issue
Block a user