MCPcopy Index your code
hub / github.com/pyfa-org/Pyfa / __addInputCheckbox

Method __addInputCheckbox

graphs/gui/ctrlPanel.py:258–268  ·  view source on GitHub ↗
(self, checkboxDef, handledHandles)

Source from the content-addressed store, hash-verified

256 self._miscInputBoxes.append(inputBox)
257
258 def __addInputCheckbox(self, checkboxDef, handledHandles):
259 if not self.__checkInputConditions(checkboxDef):
260 return
261 handledHandles.add(checkboxDef.handle)
262 fieldCheckbox = wx.CheckBox(self, wx.ID_ANY, checkboxDef.label, wx.DefaultPosition, wx.DefaultSize, 0)
263 fieldCheckbox.SetValue(self._storedConsts.get((checkboxDef.handle, None), checkboxDef.defaultValue))
264 fieldCheckbox.Bind(wx.EVT_CHECKBOX, self.OnNonMainInputChanged)
265 self.inputsSizer.Add(fieldCheckbox, 0, wx.BOTTOM, 5)
266 # Store info about added checkbox
267 checkbox = CheckBox(handle=checkboxDef.handle, checkBox=fieldCheckbox)
268 self._inputCheckboxes.append(checkbox)
269
270 def __checkInputConditions(self, inputDef):
271 if not inputDef.conditions:

Callers 1

_updateInputsMethod · 0.95

Calls 4

SetValueMethod · 0.45
getMethod · 0.45
appendMethod · 0.45

Tested by

no test coverage detected