cleanups and tweaks

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxPython/Phoenix/trunk@66465 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn
2010-12-27 18:59:06 +00:00
parent 68542755de
commit 56b229d99e
3 changed files with 6 additions and 7 deletions

View File

@@ -170,15 +170,15 @@ int wxPyApp::MainLoop()
#endif
DeletePendingObjects();
}
bool initialized = wxTopLevelWindows.GetCount() != 0;
if (initialized) {
//bool initialized = wxTopLevelWindows.GetCount() != 0;
//if (initialized) {
if ( m_exitOnFrameDelete == Later ) {
m_exitOnFrameDelete = Yes;
}
retval = wxApp::MainLoop();
OnExit();
}
//}
return retval;
}

View File

@@ -186,7 +186,7 @@ logged in on the main display of your Mac."""
def __del__(self):
self.RestoreStdio() # Just in case the MainLoop was overridden
self.RestoreStdio() # Just in case the MainLoop was overridden without calling RestoreStio
def Destroy(self):
@@ -202,8 +202,9 @@ logged in on the main display of your Mac."""
def MainLoop(self):
"""Execute the main GUI event loop"""
wx.PyApp.MainLoop(self)
rv = wx.PyApp.MainLoop(self)
self.RestoreStdio()
return rv
def RedirectStdio(self, filename=None):

View File

@@ -11,8 +11,6 @@ public:
PyObject* m_func;
};
IMPLEMENT_ABSTRACT_CLASS(wxPyCallback, wxEvtHandler);
wxPyCallback::wxPyCallback(PyObject* func) {