#11 scenery path is not loaded from saved config

open
nobody
None
5
2009-05-22
2009-05-22
Daniel
No

After loading a saved config, the scenery paths are reset to the default. I could fix this by changing the following:

File: wizard_funcs.cxx
Line: 233

if (!def_fg_scenery.empty())
{
fg_scenery = def_fg_scenery;
}
else if (prefs.get( "fg_scenery", buf, "", buflen-1))
{
fg_scenery = buf;
}

to (removed "else if")

if (!def_fg_scenery.empty())
{
fg_scenery = def_fg_scenery;
}
if (prefs.get( "fg_scenery", buf, "", buflen-1))
{
fg_scenery = buf;
}

If my understanding of the code is corrent, the if-statement should check if there exists a default scenery setting and initialize fg_scenery with the default value. After that, the scenery from the preferences should be set. This is only done if the "else if" is removed.

Greetings,
Daniel

Discussion


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks