Issue 853: fixes for OS X and Linux; as options files are changed the missing .srf format is also added to the browser

This commit is contained in:
torger
2013-11-11 19:09:11 +01:00
parent cdefd0c999
commit f22f3b5e43
6 changed files with 30 additions and 17 deletions

View File

@@ -247,6 +247,10 @@ const ProfileStoreEntry* ProfileStore::findEntryFromFullPathU(Glib::ustring path
// removing the extension
path = path.substr(0,lastdot);
// dir separator may come from options file and may be \ or /, we convert them to G_DIR_SEPARATOR_S
if (path.size() > 4 && (path[4] == '/' || path[4] == '\\'))
path = path.substr(0,4) + G_DIR_SEPARATOR_S + path.substr(5);
// removing the filename
Glib::ustring fName = Glib::path_get_basename(path);
if (!fName.empty()) {