set correct base path for winxml scripts
authorJonathan Marshall <jmarshall@never.you.mind>
Sun, 1 May 2011 21:42:59 +0000 (09:42 +1200)
committerJonathan Marshall <jmarshall@never.you.mind>
Tue, 3 May 2011 21:05:08 +0000 (09:05 +1200)
xbmc/interfaces/python/xbmcmodule/winxml.cpp
xbmc/interfaces/python/xbmcmodule/winxmldialog.cpp

index c64ab94..05ec220 100644 (file)
@@ -90,12 +90,12 @@ namespace PYXBMC
         // Finally fallback to the DefaultSkin as it didn't exist in either the XBMC Skin folder or the fallback skin folder
         CStdString str("none");
         AddonProps props(str, ADDON_SKIN, "", "");
+        props.path = URIUtils::AddFileToFolder(fallbackPath, strDefault);
         CSkinInfo::TranslateResolution(resolution, res);
         CSkinInfo skinInfo(props, res);
-        basePath = URIUtils::AddFileToFolder(fallbackPath, strDefault);
-        
-        skinInfo.Start(basePath);
-        strSkinPath = skinInfo.GetSkinPath(strXMLname, &res, basePath);
+
+        skinInfo.Start();
+        strSkinPath = skinInfo.GetSkinPath(strXMLname, &res);
         if (!XFILE::CFile::Exists(strSkinPath))
         {
           PyErr_SetString(PyExc_TypeError, "XML File for Window is missing");
index 4c13a85..6bbee0a 100644 (file)
@@ -91,13 +91,12 @@ namespace PYXBMC
         // Finally fallback to the DefaultSkin as it didn't exist in either the XBMC Skin folder or the fallback skin folder
         CStdString str("none");
         AddonProps props(str, ADDON_SKIN, "", "");
+        props.path = URIUtils::AddFileToFolder(fallbackPath, strDefault);
         CSkinInfo::TranslateResolution(resolution, res);
         CSkinInfo skinInfo(props, res);
-        
-        CStdString basePath = URIUtils::AddFileToFolder(fallbackPath, strDefault);
-        skinInfo.Start(basePath);
-        strSkinPath = skinInfo.GetSkinPath(strXMLname, &res, basePath);
-        
+
+        skinInfo.Start();
+        strSkinPath = skinInfo.GetSkinPath(strXMLname, &res);        
         if (!XFILE::CFile::Exists(strSkinPath))
         {
           PyErr_SetString(PyExc_TypeError, "XML File for Window is missing");