Update of /cvsroot/wxdevcenter/wxDevCenter/src/msw
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv20113/src/msw
Modified Files:
Config.cpp
Log Message:
Use stack to store multi path for config.
Index: Config.cpp
===================================================================
RCS file: /cvsroot/wxdevcenter/wxDevCenter/src/msw/Config.cpp,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -d -r1.6 -r1.7
*** Config.cpp 14 May 2005 12:15:56 -0000 1.6
--- Config.cpp 8 Aug 2005 19:13:58 -0000 1.7
***************
*** 59,67 ****
m_strInstallPath = ReadConfig(WXDC_CONF_KEYNAME_INSTALLDIR , wxT(""));
! m_strDataPath = ReadConfig(WXDC_CONF_KEYNAME_DATADIR , wxT(""));
! m_strFeaturesPath = ReadConfig(WXDC_CONF_KEYNAME_FEATURESDIR , wxT(""));
! m_strPluginsPath = ReadConfig(WXDC_CONF_KEYNAME_PLUGINSDIR , wxT(""));
! m_strConfPath = ReadConfig(WXDC_CONF_KEYNAME_CONFDIR , wxT(""));
! m_strUserConfPath = ReadConfig(WXDC_CONF_KEYNAME_USERCONFDIR , strDefHomeDir);
}
--- 59,67 ----
m_strInstallPath = ReadConfig(WXDC_CONF_KEYNAME_INSTALLDIR , wxT(""));
! m_strDataPath.Add( ReadConfig(WXDC_CONF_KEYNAME_DATADIR , wxT("")));
! m_strFeaturesPath.Add( ReadConfig(WXDC_CONF_KEYNAME_FEATURESDIR , wxT("")));
! m_strPluginsPath.Add( ReadConfig(WXDC_CONF_KEYNAME_PLUGINSDIR , wxT("")));
! m_strConfPath.Add( ReadConfig(WXDC_CONF_KEYNAME_CONFDIR , wxT("")));
! m_strUserConfPath.Add(ReadConfig(WXDC_CONF_KEYNAME_USERCONFDIR , strDefHomeDir));
}
***************
*** 115,145 ****
// Retourne le chemin racine des données (images, icones, etc).
! wxString ConfigWindows::GetDataPath()
{
! return m_strDataPath;
}
// Retourne le chemin racine des fonctionnalités.
! wxString ConfigWindows::GetFeaturesPath()
{
! return m_strFeaturesPath;
}
// Retourne le chemin racine des pluggins.
! wxString ConfigWindows::GetPluginsPath()
{
! return m_strPluginsPath;
}
// Retourne le chemin racine de la configuration globale.
! wxString ConfigWindows::GetGlobalConfPath()
{
! return m_strConfPath;
}
// Retourne le chemin racine de la configuration utilisateur.
! wxString ConfigWindows::GetUserConfPath()
{
! return m_strUserConfPath;
}
--- 115,160 ----
// Retourne le chemin racine des données (images, icones, etc).
! wxString ConfigWindows::GetDataPath(long lStackIndex)
{
! if(lStackIndex>=0l && lStackIndex<(long)m_strDataPath.GetCount())
! return m_strDataPath[lStackIndex];
! else
! return wxT("");
}
// Retourne le chemin racine des fonctionnalités.
! wxString ConfigWindows::GetFeaturesPath(long lStackIndex)
{
! if(lStackIndex>=0l && lStackIndex<(long)m_strFeaturesPath.GetCount())
! return m_strFeaturesPath[lStackIndex];
! else
! return wxT("");
}
// Retourne le chemin racine des pluggins.
! wxString ConfigWindows::GetPluginsPath(long lStackIndex)
{
! if(lStackIndex>=0l && lStackIndex<(long)m_strPluginsPath.GetCount())
! return m_strPluginsPath[lStackIndex];
! else
! return wxT("");
}
// Retourne le chemin racine de la configuration globale.
! wxString ConfigWindows::GetGlobalConfPath(long lStackIndex)
{
! if(lStackIndex>=0l && lStackIndex<(long)m_strConfPath.GetCount())
! return m_strConfPath[lStackIndex];
! else
! return wxT("");
}
// Retourne le chemin racine de la configuration utilisateur.
! wxString ConfigWindows::GetUserConfPath(long lStackIndex)
{
! if(lStackIndex>=0l && lStackIndex<(long)m_strUserConfPath.GetCount())
! return m_strUserConfPath[lStackIndex];
! else
! return wxT("");
}
|