Patch #1594554: Always close a tkSimpleDialog on ok(), even
if an exception occurs. Will backport to 2.5.
This commit is contained in:
parent
c73a4a4f51
commit
ef5fd3e7c9
|
@ -129,9 +129,10 @@ class Dialog(Toplevel):
|
|||
self.withdraw()
|
||||
self.update_idletasks()
|
||||
|
||||
self.apply()
|
||||
|
||||
self.cancel()
|
||||
try:
|
||||
self.apply()
|
||||
finally:
|
||||
self.cancel()
|
||||
|
||||
def cancel(self, event=None):
|
||||
|
||||
|
|
Loading…
Reference in New Issue