X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/293a0a8677c1ea28e42d4a97c3ec9c2a757d1c0c..8262f9aecb42cefb62a6c574812a2db3dcc33661:/wxPython/src/_extras.py diff --git a/wxPython/src/_extras.py b/wxPython/src/_extras.py index a3aa030977..f1733cee51 100644 --- a/wxPython/src/_extras.py +++ b/wxPython/src/_extras.py @@ -98,6 +98,9 @@ def EVT_INIT_DIALOG(win, func): def EVT_SYS_COLOUR_CHANGED(win, func): win.Connect(-1, -1, wxEVT_SYS_COLOUR_CHANGED, func) +def EVT_DISPLAY_CHANGED(win, func): + win.Connect(-1, -1, wxEVT_DISPLAY_CHANGED, func) + def EVT_SHOW(win, func): win.Connect(-1, -1, wxEVT_SHOW, func) @@ -778,7 +781,15 @@ class __wxPyCleanup: def __del__(self): self.cleanup() -__cleanMeUp = __wxPyCleanup() +sys.__wxPythonCleanup = __wxPyCleanup() + +## # another possible solution, but it gets called too early... +## if sys.version[0] == '2': +## import atexit +## atexit.register(wxc.wxApp_CleanUp) +## else: +## sys.exitfunc = wxc.wxApp_CleanUp + #---------------------------------------------------------------------------- #----------------------------------------------------------------------------