X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/dde19c2180ef8d6415af7bb2492bfcb0a2d5c7e4..12bb29f5432174ecbd65549bda832d70d34a98ae:/src/motif/app.cpp diff --git a/src/motif/app.cpp b/src/motif/app.cpp index 0a073548e7..4216c8796e 100644 --- a/src/motif/app.cpp +++ b/src/motif/app.cpp @@ -68,7 +68,6 @@ wxHashTable *wxWidgetHashTable = NULL; IMPLEMENT_DYNAMIC_CLASS(wxApp, wxEvtHandler) -#ifdef __WXDEBUG__ extern "C" { typedef int (*XErrorHandlerFunc)(Display *, XErrorEvent *); @@ -86,7 +85,6 @@ static int wxXErrorHandler(Display *dpy, XErrorEvent *xevent) } } -#endif // __WXDEBUG__ bool wxApp::Initialize(int& argc_, wxChar **argv_) { @@ -126,7 +124,7 @@ bool wxApp::Initialize(int& argc_, wxChar **argv_) strcmp(loc, "POSIX") == 0 ) { // we're using C locale, "fix" it - wxLogDebug(_T("HP-UX fontset hack: forcing locale to en_US.iso88591")); + wxLogDebug(wxT("HP-UX fontset hack: forcing locale to en_US.iso88591")); putenv(fixAll ? "LC_ALL=en_US.iso88591" : "LC_CTYPE=en_US.iso88591"); } #endif // __HPUX__ @@ -164,10 +162,10 @@ bool wxApp::Initialize(int& argc_, wxChar **argv_) // immediate crash inside XOpenIM() (if XIM is used) under IRIX wxString appname = wxTheApp->GetAppName(); if ( appname.empty() ) - appname = _T("wxapp"); + appname = wxT("wxapp"); wxString clsname = wxTheApp->GetClassName(); if ( clsname.empty() ) - clsname = _T("wx"); + clsname = wxT("wx"); // FIXME-UTF8: This code is taken from wxGTK and duplicated here. This // is just a temporary fix to make wxX11 compile in Unicode @@ -251,10 +249,8 @@ bool wxApp::Initialize(int& argc_, wxChar **argv_) } m_initialDisplay = (WXDisplay*) dpy; -#ifdef __WXDEBUG__ // install the X error handler gs_pfnXErrorHandler = XSetErrorHandler(wxXErrorHandler); -#endif // __WXDEBUG__ // Add general resize proc XtActionsRec rec; @@ -273,8 +269,7 @@ void wxApp::CleanUp() { wxAppBase::CleanUp(); - delete wxWidgetHashTable; - wxWidgetHashTable = NULL; + wxDELETE(wxWidgetHashTable); delete m_mainLoop;