|
From: Emilien K. <cur...@us...> - 2005-02-23 14:21:30
|
Update of /cvsroot/wxdevcenter/wxDevCenter/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5705/src Modified Files: Config.cpp Log Message: Transfert de la fonction Config::CreateSubConfig vers les spécialisations unix et msw. Index: Config.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/Config.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Config.cpp 23 Feb 2005 11:43:56 -0000 1.5 --- Config.cpp 23 Feb 2005 14:21:21 -0000 1.6 *************** *** 73,108 **** } - // Crée une sous-configuration et la place dans le dictionnaire. - bool Config::CreateSubConfig(wxString strSubConfName) - { - wxFileConfig* pFC; - wxString strAppName, strDir; - strAppName << WXDC_SETUP_APPIDENT << wxT("/") << strSubConfName; - - // Création du répertoire de config global - strDir = GetGlobalConfPath() + wxT("/") + strSubConfName; - strDir.Replace(wxT("\\"), wxT("/")); - strDir = strDir.BeforeLast(wxT('/')); - if(!wxDirExists(strDir)) - wxMkDir(strDir); - // Création du répertoire de config utilisateur - strDir = GetUserConfPath() + wxT("/") + strSubConfName; - strDir.Replace(wxT("\\"), wxT("/")); - strDir = strDir.BeforeLast(wxT('/')); - if(!wxDirExists(strDir)) - wxMkDir(strDir); - - pFC = new wxFileConfig(strAppName, WXDC_SETUP_VENDOR, - GetUserConfPath() + wxT("/") + strSubConfName + wxT(".conf"), - GetGlobalConfPath() + wxT("/") + strSubConfName + wxT(".conf")); - - wxConfigBase* pConf = m_SubConfigMap[strSubConfName]; - if(pConf!=NULL) - delete pConf; - m_SubConfigMap[strSubConfName] = pFC; - - return true; - } - // Vide le buffer des sous-configurations. void Config::CloseSubConfig() --- 73,76 ---- |