git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31220
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
void wxLocale::DoCommonInit()
{
m_pszOldLocale = NULL;
- m_pOldLocale = NULL;
+
+ m_pOldLocale = wxSetLocale(this);
+
m_pMsgCat = NULL;
m_language = wxLANGUAGE_UNKNOWN;
m_initialized = false;
}
}
- // save the old locale to be able to restore it later
- m_pOldLocale = wxSetLocale(this);
-
// load the default catalog with wxWidgets standard messages
m_pMsgCat = NULL;
bool bOk = true;
delete pTmpCat;
}
- // restore old locale if we had changed it
- if ( m_pOldLocale )
- wxSetLocale(m_pOldLocale);
+ // restore old locale pointer
+ wxSetLocale(m_pOldLocale);
// FIXME
#ifndef __WXWINCE__