From b9d79d0d368cccd31e0c00062b3fb3a26da3b1b8 Mon Sep 17 00:00:00 2001 From: Noldor Date: Wed, 16 Mar 2011 21:58:18 +0000 Subject: Code improvements in the theme manager(wip) git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@5610 17fca916-40b9-46aa-a4ea-0a15b648b75c --- src/modules/theme/libkvitheme.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/modules/theme/libkvitheme.cpp') diff --git a/src/modules/theme/libkvitheme.cpp b/src/modules/theme/libkvitheme.cpp index 86425b9a7..3422291cc 100644 --- a/src/modules/theme/libkvitheme.cpp +++ b/src/modules/theme/libkvitheme.cpp @@ -101,14 +101,15 @@ static bool theme_kvs_cmd_apply(KviKvsModuleCommandCall * c) szDir += KVI_PATH_SEPARATOR_CHAR; szDir += szThemePackFile; KviThemeInfo * themeInfo = new KviThemeInfo(); - if(themeInfo->loadFromDirectory(szDir)) + if(themeInfo->load(szDir)) { themeInfo->setSubdirectory(szThemePackFile); if(KviMessageBox::yesNo(__tr2qs_ctx("Apply theme - KVIrc","theme"), __tr2qs_ctx("Do you wish to apply theme \"%Q\" (version %Q)?","theme"), &(themeInfo->name()),&(themeInfo->version()))) { - QString szPath = themeInfo->absoluteDirectory(); + QString szPath; + themeInfo->getCompleteDirPath(szPath); if(szPath.isEmpty())return true; KviThemeInfo out; @@ -151,7 +152,7 @@ static bool theme_kvs_fnc_info(KviKvsModuleFunctionCall * c) szDir += KVI_PATH_SEPARATOR_CHAR; szDir += szThemePackFile; KviThemeInfo * themeInfo = new KviThemeInfo(); - if(themeInfo->loadFromDirectory(szDir)) + if(themeInfo->load(szDir)) { KviKvsHash *pHash=new KviKvsHash(); KviKvsVariant *name=new KviKvsVariant(themeInfo->name()); -- cgit v1.3.1-10-gc9f91