def _setSliceInteraction(self, sliceName, interaction): if sliceName in self._sliceDirectionsDict: sd = self._sliceDirectionsDict[sliceName] if interaction: sd.enableInteraction() else: sd.disableInteraction() row = self._findGridRowByName(sliceName) if row >= 0: gen_utils.setGridCellYesNo( self._grid, row, self._gridInteractionCol, interaction)
def _setSliceEnabled(self, sliceName, enabled): if sliceName in self._sliceDirectionsDict: sd = self._sliceDirectionsDict[sliceName] if enabled: sd.enable() else: sd.disable() row = self._findGridRowByName(sliceName) if row >= 0: gen_utils.setGridCellYesNo( self._grid, row, self._gridEnabledCol, enabled)
def _setImplicitEnabled(self, implicitName, enabled): if implicitName in self._implicitsDict: ii = self._implicitsDict[implicitName] # in our internal list ii.enabled = bool(enabled) # the widget if ii.widget: ii.widget.SetEnabled(ii.enabled) # in the grid gridRow = self.findGridRowByName(implicitName) if gridRow >= 0: gen_utils.setGridCellYesNo( self._grid, gridRow, self._gridEnabledCol, ii.enabled)