Main change is that we now close X11 display on program exit: as this couldn't

be done in wxApp dtor (too early), a special module had to be created for it
and module dependencies added for the other modules which have to be cleaned
up while the display is still open.

Also a few minor formatting changes and removed a couple of unused variables
from wxApp.


git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@42119 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2006-10-19 14:39:53 +00:00
parent 36751d973e
commit b886fae648
6 changed files with 117 additions and 119 deletions

View File

@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////////
// Name: app.h
// Name: wx/x11/app.h
// Purpose: wxApp class
// Author: Julian Smart
// Modified by:
@@ -9,8 +9,8 @@
// Licence: wxWindows licence
/////////////////////////////////////////////////////////////////////////////
#ifndef _WX_APP_H_
#define _WX_APP_H_
#ifndef _WX_X11_APP_H_
#define _WX_X11_APP_H_
// ----------------------------------------------------------------------------
// headers
@@ -36,8 +36,6 @@ class WXDLLEXPORT wxXVisualInfo;
class WXDLLEXPORT wxApp : public wxAppBase
{
DECLARE_DYNAMIC_CLASS(wxApp)
public:
wxApp();
virtual ~wxApp();
@@ -62,9 +60,6 @@ public:
virtual void OnAssert(const wxChar *file, int line, const wxChar* cond, const wxChar *msg);
#endif // __WXDEBUG__
protected:
bool m_showOnInit;
public:
// Implementation
virtual bool Initialize(int& argc, wxChar **argv);
@@ -96,10 +91,6 @@ public:
return m_visualInfo;
}
// We need this before creating the app
static WXDisplay* GetDisplay() { return ms_display; }
static WXDisplay* ms_display;
public:
static long sm_lastMessageTime;
bool m_showIconic;
@@ -110,14 +101,13 @@ public:
#endif
protected:
bool m_keepGoing;
WXWindow m_topLevelWidget;
WXColormap m_mainColormap;
long m_maxRequestSize;
DECLARE_DYNAMIC_CLASS(wxApp)
DECLARE_EVENT_TABLE()
};
#endif // _WX_APP_H_
#endif // _WX_X11_APP_H_