|
|
|
@ -2288,10 +2288,13 @@ struct GameSettingsWindow : Window {
|
|
|
|
|
/* Show the correct currency-translated value */
|
|
|
|
|
if (sd->flags & SF_GUI_CURRENCY) value64 *= _currency->rate;
|
|
|
|
|
|
|
|
|
|
CharSetFilter charset_filter = CS_NUMERAL; //default, only numeric input allowed
|
|
|
|
|
if (sd->min < 0) charset_filter = CS_NUMERAL_SIGNED; // special case, also allow '-' sign for negative input
|
|
|
|
|
|
|
|
|
|
this->valuewindow_entry = pe;
|
|
|
|
|
SetDParam(0, value64);
|
|
|
|
|
/* Limit string length to 14 so that MAX_INT32 * max currency rate doesn't exceed MAX_INT64. */
|
|
|
|
|
ShowQueryString(STR_JUST_INT, STR_CONFIG_SETTING_QUERY_CAPTION, 15, this, CS_NUMERAL, QSF_ENABLE_DEFAULT);
|
|
|
|
|
ShowQueryString(STR_JUST_INT, STR_CONFIG_SETTING_QUERY_CAPTION, 15, this, charset_filter, QSF_ENABLE_DEFAULT);
|
|
|
|
|
}
|
|
|
|
|
this->SetDisplayedHelpText(pe);
|
|
|
|
|
}
|
|
|
|
|