Skip to content

Commit

Permalink
Fixed|Client: Setting up the Custom profile
Browse files Browse the repository at this point in the history
If there are no previously saved profiles, make sure the Custom
profile gets created with the user's current settings.
  • Loading branch information
skyjake committed Oct 2, 2013
1 parent 3e86d1a commit b815564
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions doomsday/client/src/settingsregister.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -398,13 +398,24 @@ DENG2_OBSERVES(App, GameChange)
{
loadProfilesFromInfo(*file, false /* modifiable */);
}
else
{
// Settings haven't previously been created -- make sure we at least
// have the Custom profile.
if(!profiles.contains(CUSTOM_PROFILE))
{
addProfile(CUSTOM_PROFILE);

// Make sure we at least have the Custom profile.
// Use whatever values are currently in effect.
fetch(CUSTOM_PROFILE);
current = CUSTOM_PROFILE;
}
}

// Still nothing?
if(profiles.isEmpty())
{
addProfile(CUSTOM_PROFILE);

// Use whatever values are currently in effect.
fetch(CUSTOM_PROFILE);
}

Expand Down

0 comments on commit b815564

Please sign in to comment.