mirror of
https://github.com/OpenTTD/OpenTTD
synced 2026-01-22 19:54:06 +01:00
Codechange: Pass raw string to editable query window. (#13481)
This avoids separating string id and parameters. EncodedString is not needed as it is the raw text that is editable.
This commit is contained in:
@@ -1099,12 +1099,11 @@ public:
|
||||
{
|
||||
assert(Group::IsValidID(group));
|
||||
this->group_rename = group;
|
||||
|
||||
/* Show empty query for new groups */
|
||||
StringID str = STR_EMPTY;
|
||||
if (!empty) {
|
||||
SetDParam(0, group);
|
||||
str = STR_GROUP_NAME;
|
||||
}
|
||||
std::string str;
|
||||
if (!empty) str = GetString(STR_GROUP_NAME, group);
|
||||
|
||||
ShowQueryString(str, STR_GROUP_RENAME_CAPTION, MAX_LENGTH_GROUP_NAME_CHARS, this, CS_ALPHANUMERAL, QSF_ENABLE_DEFAULT | QSF_LEN_IN_CHARS);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user