diff options
Diffstat (limited to 'xbmc/utils/Addon.cpp')
-rw-r--r-- | xbmc/utils/Addon.cpp | 21 |
1 files changed, 6 insertions, 15 deletions
diff --git a/xbmc/utils/Addon.cpp b/xbmc/utils/Addon.cpp index b228a2bb20..7198385bfd 100644 --- a/xbmc/utils/Addon.cpp +++ b/xbmc/utils/Addon.cpp @@ -226,8 +226,8 @@ CAddon::CAddon(const AddonProps &props) { if (props.libname.empty()) BuildLibName(); else m_strLibName = props.libname; - m_strProfile = GetProfilePath(); - m_userSettingsPath = GetUserSettingsPath(); + BuildProfilePath(); + m_userSettingsPath = m_profile + "settings.xml"; m_disabled = true; } @@ -237,8 +237,8 @@ CAddon::CAddon(const CAddon &rhs, const AddonPtr &parent) { m_props.uuid = StringUtils::CreateUUID(); m_userXmlDoc = rhs.m_userXmlDoc; - m_strProfile = GetProfilePath(); - m_userSettingsPath = GetUserSettingsPath(); + BuildProfilePath(); + m_userSettingsPath = m_profile + "settings.xml"; m_strLibName = rhs.LibName(); m_disabled = false; } @@ -501,18 +501,9 @@ TiXmlElement* CAddon::GetSettingsXML() return m_addonXmlDoc.RootElement(); } -CStdString CAddon::GetProfilePath() +void CAddon::BuildProfilePath() { - CStdString profile; - profile.Format("special://profile/addon_data/%s/", UUID().c_str()); - return profile; -} - -CStdString CAddon::GetUserSettingsPath() -{ - CStdString path; - CUtil::AddFileToFolder(Profile(), "settings.xml", path); - return path; + m_profile.Format("special://profile/addon_data/%s/", UUID().c_str()); } /** |