mirror of
https://github.com/hedge-dev/UnleashedRecomp.git
synced 2025-10-30 07:11:05 +00:00
fix options menu reset to default logic getting executed when setting is already default (#461)
This commit is contained in:
parent
388a86e866
commit
0b16633ee1
1 changed files with 10 additions and 7 deletions
|
|
@ -859,16 +859,19 @@ static void DrawConfigOption(int32_t rowIndex, float yOffset, ConfigDef<T>* conf
|
|||
|
||||
if (g_canReset && padState.IsTapped(SWA::eKeyState_X))
|
||||
{
|
||||
config->MakeDefault();
|
||||
if (!config->IsDefaultValue())
|
||||
{
|
||||
config->MakeDefault();
|
||||
|
||||
VideoConfigValueChangedCallback(config);
|
||||
XAudioConfigValueChangedCallback(config);
|
||||
VideoConfigValueChangedCallback(config);
|
||||
XAudioConfigValueChangedCallback(config);
|
||||
|
||||
if (config->Callback)
|
||||
config->Callback(config);
|
||||
if (config->Callback)
|
||||
config->Callback(config);
|
||||
|
||||
if (config->ApplyCallback)
|
||||
config->ApplyCallback(config);
|
||||
if (config->ApplyCallback)
|
||||
config->ApplyCallback(config);
|
||||
}
|
||||
|
||||
Game_PlaySound("sys_worldmap_decide");
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue