|
From: Emilien K. <cur...@us...> - 2005-09-15 16:12:08
|
Update of /cvsroot/wxdevcenter/StdPlugin/src/Text In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv10110/src/Text Modified Files: SimpleTextDocView.cpp Log Message: Modularize Config. Use Config::GetConfig to retreive the unique config object. Index: SimpleTextDocView.cpp =================================================================== RCS file: /cvsroot/wxdevcenter/StdPlugin/src/Text/SimpleTextDocView.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** SimpleTextDocView.cpp 14 Sep 2005 20:17:07 -0000 1.3 --- SimpleTextDocView.cpp 15 Sep 2005 16:11:55 -0000 1.4 *************** *** 26,30 **** --- 26,32 ---- #include <wxDevCenter/StdPlugin/Text/SimpleTextDocView.h> + #include <wxDevCenter/ArtProvider.h> + #include <wxDevCenter/Config.h> #include <wx/stream.h> *************** *** 202,206 **** LanguageProperty::LangagePropertyStyle* pCurStyle; ! wxConfigBase& GlobalConfig = Application::GetApp().GetConfig()[WXDC_SIMPLETEXT_CONFIG_ROOT]; GlobalConfig.SetPath(wxT("/")); --- 204,208 ---- LanguageProperty::LangagePropertyStyle* pCurStyle; ! wxConfigBase& GlobalConfig = Config::GetConfig().GetSubConfig(WXDC_SIMPLETEXT_CONFIG_ROOT); GlobalConfig.SetPath(wxT("/")); *************** *** 212,216 **** strRoot.Empty(); strRoot << WXDC_SIMPLETEXT_CONFIG_ROOT << wxT("/") << pLang->strShortName; ! wxConfigBase& Config = Application::GetApp().GetConfig()[strRoot]; Config.SetPath(wxT("/")); --- 214,218 ---- strRoot.Empty(); strRoot << WXDC_SIMPLETEXT_CONFIG_ROOT << wxT("/") << pLang->strShortName; ! wxConfigBase& Config = Config::GetConfig().GetSubConfig(strRoot); Config.SetPath(wxT("/")); *************** *** 253,257 **** LanguageProperty::LangagePropertyStyle* pCurStyle; ! wxConfigBase& GlobalConfig = Application::GetApp().GetConfig()[WXDC_SIMPLETEXT_CONFIG_ROOT]; GlobalConfig.SetPath(wxT("/")); --- 255,259 ---- LanguageProperty::LangagePropertyStyle* pCurStyle; ! wxConfigBase& GlobalConfig = Config::GetConfig()[WXDC_SIMPLETEXT_CONFIG_ROOT]; GlobalConfig.SetPath(wxT("/")); *************** *** 263,267 **** strRoot.Empty(); strRoot << WXDC_SIMPLETEXT_CONFIG_ROOT << wxT("/") << pLang->strShortName; ! wxConfigBase& Config = Application::GetApp().GetConfig()[strRoot]; Config.SetPath(wxT("/")); --- 265,269 ---- strRoot.Empty(); strRoot << WXDC_SIMPLETEXT_CONFIG_ROOT << wxT("/") << pLang->strShortName; ! wxConfigBase& Config = Config::GetConfig()[strRoot]; Config.SetPath(wxT("/")); |