Adding a item path property and setting default path for if baseItemPath did not exist.

This commit is contained in:
emb
2015-01-17 13:04:54 -06:00
parent b19dd4b822
commit 5c48661f7b
5 changed files with 24 additions and 41 deletions

View File

@@ -265,18 +265,11 @@ bool Launcher::GetExtensions(std::string &extensions, std::string collection)
bool Launcher::GetCollectionDirectory(std::string &directory, std::string collection)
{
std::string itemsPathKey = "collections." + collection + ".list.path";
std::string itemsPathValue;
// find the items path folder (i.e. ROM path)
if(!Config.GetPropertyAbsolutePath(itemsPathKey, itemsPathValue))
{
directory = "";
}
else
{
directory += itemsPathValue + "/";
}
Config.GetCollectionAbsolutePath(collection, itemsPathValue);
directory += itemsPathValue + "/";
return true;
}