+ # when the entry to invalidate does not exist, just ignore the request.
+ # this eases up conditional setup screens a lot.
+ if entry in self.__list:
+ self.l.invalidateEntry(self.__list.index(entry))
+
+ GUI_WIDGET = eListbox
+
+ def selectionChanged(self):
+ n = self.getCurrent()
+
+ if self.help_window:
+ self.session.deleteDialog(self.help_window)
+
+ nh = n and n[1].helpWindow()
+ if nh is not None and self.session is not None:
+ self.help_window = self.session.instantiateDialog(*nh)
+ self.help_window.show()
+
+ self.current = n
+ for x in self.onSelectionChanged:
+ x()
+
+ def postWidgetCreate(self, instance):
+ instance.setContent(self.l)
+ instance.selectionChanged.get().append(self.selectionChanged)
+
+ def preWidgetRemove(self, instance):
+ instance.selectionChanged.get().remove(self.selectionChanged)
+
+ def setList(self, l):
+ self.timer.stop()
+ self.__list = l
+ self.l.setList(self.__list)
+
+ if l is not None:
+ for x in l:
+ assert isinstance(x[1], ConfigElement), "entry in ConfigList " + str(x[1]) + " must be a ConfigElement"
+
+ def getList(self):
+ return self.__list
+
+ list = property(getList, setList)
+
+ def timeout(self):
+ self.handleKey(KEY_TIMEOUT)
+
+ def isChanged(self):
+ is_changed = False