def create_checkbox_hbox(self, label, value, trace, sensitivity_group, constraints=None):
hbox_main = gtk.HBox()
checkbutton_option = gtk.CheckButton(label.title())
checkbutton_option.set_active(value)
if label.lower() == "enabled":
checkbutton_option.connect("toggled", self.enabled_checkbox_toggled, sensitivity_group)
hbox_main.pack_start(checkbutton_option)
self.plugin_config_widgets.append(checkbutton_option)
self.plugin_config_traces.append(trace)
sensitivity_group.append(checkbutton_option)
self.sensitivity_groups.append(sensitivity_group)
self.sensitivity_groups_switch.append(checkbutton_option)
return hbox_main
评论列表
文章目录