Fix exception on removing the last custombutton when there are no other custombuttons
parent
16fd9fd04d
commit
0da65f14d0
|
@ -727,7 +727,7 @@ class PronterWindow(wx.Frame,pronsole.pronsole):
|
|||
n = button.custombutton
|
||||
self.custombuttons[n]=None
|
||||
self.cbutton_save(n,None)
|
||||
while self.custombuttons[-1] is None:
|
||||
while len(self.custombuttons) and self.custombuttons[-1] is None:
|
||||
del self.custombuttons[-1]
|
||||
self.cbuttons_reload()
|
||||
|
||||
|
|
Loading…
Reference in New Issue