# after the last window closes but before wxPython’s internal cleanup. # normal shutdown # wx.App.OnExit() # Even if the application is closed with wx.Exit(), the OnExit() method is still triggered. # emergency shutdown # 1. wx.App.ExitMainLoop() # 2. wx.Exit() def OnExit(self): print "OnExit"
本文探讨了wxPython应用程序正常及紧急关闭时的处理过程,包括`wx.App.OnExit()`方法的作用及其触发时机,以及两种紧急关闭方式:`wx.App.ExitMainLoop()`和`wx.Exit()`。
3511

被折叠的 条评论
为什么被折叠?



