mirror of https://github.com/BOINC/boinc.git
- fixes #4 - BOINC Manager should be able to find it's
localization files. BOINCMgr will now check in the absolute path in which it was installed as well as the relative path from where it was executed from. clientgui/ BOINCGUIApp.cpp, .h svn path=/trunk/boinc/; revision=12602
This commit is contained in:
parent
7f76e8aeeb
commit
6904f5acc6
|
@ -4524,4 +4524,15 @@ Rom 7 May 2007
|
|||
clientgui/
|
||||
sg_ImageLoader.cpp
|
||||
sg_ProjectsComponent.cpp, .h
|
||||
|
||||
|
||||
Rom 7 May 2007
|
||||
- fixes #4 - BOINC Manager should be able to find it's
|
||||
localization files.
|
||||
|
||||
BOINCMgr will now check in the absolute path in which
|
||||
it was installed as well as the relative path from where
|
||||
it was executed from.
|
||||
|
||||
|
||||
clientgui/
|
||||
BOINCGUIApp.cpp, .h
|
||||
|
|
|
@ -77,6 +77,7 @@ bool CBOINCGUIApp::OnInit() {
|
|||
// Setup variables with default values
|
||||
m_bBOINCStartedByManager = false;
|
||||
m_strBOINCArguments = wxEmptyString;
|
||||
m_strBOINCMGRRootDirectory = wxEmptyString;
|
||||
m_pLocale = NULL;
|
||||
m_pSkinManager = NULL;
|
||||
m_pFrame = NULL;
|
||||
|
@ -142,6 +143,9 @@ bool CBOINCGUIApp::OnInit() {
|
|||
SetCurrentDirectory(szPath);
|
||||
}
|
||||
|
||||
// Store the root directory for later use.
|
||||
m_strBOINCMGRRootDirectory = szPath;
|
||||
|
||||
#endif
|
||||
|
||||
#ifdef __WXMAC__
|
||||
|
@ -238,8 +242,14 @@ bool CBOINCGUIApp::OnInit() {
|
|||
|
||||
wxInt32 iSelectedLanguage = m_pConfig->Read(wxT("Language"), 0L);
|
||||
|
||||
// Locale information is stored relative to the executable.
|
||||
// Look for the localization files by absolute and relative locations.
|
||||
// preference given to the absolute location.
|
||||
m_pLocale->Init(iSelectedLanguage);
|
||||
if (!m_strBOINCMGRRootDirectory.IsEmpty()) {
|
||||
m_pLocale->AddCatalogLookupPathPrefix(
|
||||
wxString(m_strBOINCMGRRootDirectory + wxT("locale")).c_str()
|
||||
);
|
||||
}
|
||||
m_pLocale->AddCatalogLookupPathPrefix(wxT("locale"));
|
||||
m_pLocale->AddCatalog(wxT("BOINC Manager"));
|
||||
|
||||
|
|
|
@ -76,6 +76,7 @@ protected:
|
|||
#endif
|
||||
|
||||
bool m_bBOINCStartedByManager;
|
||||
wxString m_strBOINCMGRRootDirectory;
|
||||
wxString m_strBOINCArguments;
|
||||
|
||||
int m_iDisplayExitWarning;
|
||||
|
|
Loading…
Reference in New Issue