This covers the code changes for the datadir move (which is now finished)

Based on darix' patch I wrote this. Modperl's changes were not tested since I
didn't find someone who could test it. Well...

Ah and btw it regenerates configure


git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@902 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
psychon
2007-12-12 21:15:44 +00:00
parent 608fbdbdb0
commit 1360effd31
8 changed files with 105 additions and 72 deletions
+3 -12
View File
@@ -221,23 +221,14 @@ private:
};
CString CWebAdminSock::GetSkinDir() {
CString sModPath = CZNC::Get().FindModPath(m_pModule->GetModName()); // @todo store the path to the module at load time and store it in a member var which can be used here
// Remove the file.so portion from the path
while (!sModPath.empty() && sModPath.Right(1) != "/") {
sModPath.RightChomp();
}
// Remove the last /
sModPath.RightChomp();
CString sSkinDir = sModPath + "/" + m_pModule->GetModName() + "/skins/" + m_pModule->GetSkinName() + "/";
CString sSkinDir = m_pModule->GetModDataDir() + "/skins/"
+ m_pModule->GetSkinName() + "/";
if (CDir::Exists(sSkinDir)) {
return sSkinDir;
}
return sModPath + "/" + m_pModule->GetModName() + "/skins/default/";
return m_pModule->GetModDataDir() + "/skins/default/";
}
void CWebAdminSock::PrintPage(CString& sPageRet, const CString& sTmplName) {