eliminate duplicate check on allowUsedSpaceTxtUpdate

This commit is contained in:
w3irDv 2024-07-27 11:13:19 +02:00
parent d507ba5ed1
commit 35aac59bd8

View File

@ -1693,13 +1693,12 @@ void GameBrowseMenu::UpdateCallback(void * e)
void GameBrowseMenu::SetFreeSpace(float freespace, float used) void GameBrowseMenu::SetFreeSpace(float freespace, float used)
{ {
if (strcmp(Settings.db_language, "JA") == 0) { if ( allowUsedSpaceTxtUpdate == true ) {
if ( allowUsedSpaceTxtUpdate == true ) if (strcmp(Settings.db_language, "JA") == 0)
usedSpaceTxt->SetText(fmt("%.2fGB %s %.2fGB %s", freespace + used, tr( "of" ), freespace, tr( "free" ))); usedSpaceTxt->SetText(fmt("%.2fGB %s %.2fGB %s", freespace + used, tr( "of" ), freespace, tr( "free" )));
} else
else
if ( allowUsedSpaceTxtUpdate == true )
usedSpaceTxt->SetText(fmt("%.2fGB %s %.2fGB %s", freespace, tr( "of" ), freespace + used, tr( "free" ))); usedSpaceTxt->SetText(fmt("%.2fGB %s %.2fGB %s", freespace, tr( "of" ), freespace + used, tr( "free" )));
}
} }
void GameBrowseMenu::UpdateFreeSpace(void * arg) void GameBrowseMenu::UpdateFreeSpace(void * arg)