From: <cl...@us...> - 2003-04-26 22:20:29
|
Update of /cvsroot/todo-manager/todo-manager In directory sc8-pr-cvs1:/tmp/cvs-serv1094 Modified Files: optionsdialog.py Log Message: If the list was blank, an error occured when the listbox was clicked Index: optionsdialog.py =================================================================== RCS file: /cvsroot/todo-manager/todo-manager/optionsdialog.py,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- optionsdialog.py 11 Mar 2003 03:41:40 -0000 1.9 +++ optionsdialog.py 26 Apr 2003 22:20:24 -0000 1.10 @@ -450,7 +450,12 @@ plglist.insert(END, p['name']) def __OnSelectPlugin(self, event): - i = int(event.widget.curselection()[0]) + cs = event.widget.curselection() + if not cs: + # If there is no selection, then just stop + return + + i = int(cs[0]) p = self.plugins[i] # Set the state to normal so text can be added |