added outputImageTypes in node desc to update the viewer2D imageType combo box when double clicking a node

This commit is contained in:
Loïc Vital 2022-09-16 17:01:07 +02:00 committed by Fabien Castan
parent ab0e132121
commit fc5ab540f5
5 changed files with 18 additions and 1 deletions

View file

@ -568,6 +568,9 @@ class BaseNode(BaseObject):
def getAttributes(self):
return self._attributes
def getOutputImageTypes(self):
return self.nodeDesc.outputImageTypes
@Slot(str, result=bool)
def hasAttribute(self, name):
return name in self._attributes.keys()
@ -1053,6 +1056,7 @@ class BaseNode(BaseObject):
x = Property(float, lambda self: self._position.x, notify=positionChanged)
y = Property(float, lambda self: self._position.y, notify=positionChanged)
attributes = Property(BaseObject, getAttributes, constant=True)
outputImageTypes = Property(Variant, getOutputImageTypes, constant=True)
internalFolderChanged = Signal()
internalFolder = Property(str, internalFolder.fget, notify=internalFolderChanged)
depthChanged = Signal()