예제 #1
0
 def createInputWidgets(self, inputsCategory, group=None, pins=True):
     validVars = self.graph().getVarList()
     cbVars = EnumComboBox([v.name for v in validVars])
     if self.var is not None:
         cbVars.setCurrentText(self.var.name)
     else:
         cbVars.setCurrentText("")
     cbVars.changeCallback.connect(self.onVarSelected)
     inputsCategory.addWidget("var", cbVars, group=group)
예제 #2
0
 def createInputWidgets(self, inputsCategory, inGroup=None, pins=True):
     inputsCategory.setButtonName("Variable")
     validVars = self.graph().getVarList()
     cbVars = EnumComboBox([v.name for v in validVars])
     if self.var is not None:
         cbVars.setCurrentText(self.var.name)
     else:
         cbVars.setCurrentText("")
     cbVars.changeCallback.connect(self.onVarSelected)
     inputsCategory.addWidget("var", cbVars, group=inGroup)
     if pins:
         super(UISetVarNode,
               self).createInputWidgets(inputsCategory, inGroup)
예제 #3
0
class ObjectPathWIdget(InputWidgetSingle):
    """docstring for ObjectPathWIdget."""
    def __init__(self, parent=None, **kwds):
        super(ObjectPathWIdget, self).__init__(parent=parent, **kwds)
        values = []
        self.enumBox = EnumComboBox(PathsRegistry().getAllPaths())
        self.setWidget(self.enumBox)
        self.enumBox.changeCallback.connect(self.dataSetCallback)

    def blockWidgetSignals(self, bLock=False):
        self.enumBox.blockSignals(bLock)

    def setWidgetValue(self, value):
        self.enumBox.setCurrentText(value)