mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2026-07-24 20:12:42 +00:00
Fix: Company query popups do not update in multiplayer.
This commit is contained in:
@@ -1069,6 +1069,16 @@ void ShowQueryString(std::string_view str, StringID caption, uint maxsize, Windo
|
||||
new QueryStringWindow(str, caption, (flags.Test(QueryStringFlag::LengthIsInChars) ? MAX_CHAR_LENGTH : 1) * maxsize, maxsize, _query_string_desc, parent, afilter, flags);
|
||||
}
|
||||
|
||||
/**
|
||||
* Updates default text value of query strign window.
|
||||
* @param str String for the default text shown in the textbox.
|
||||
*/
|
||||
void UpdateQueryStringDefault(std::string_view str)
|
||||
{
|
||||
QueryStringWindow *w = dynamic_cast<QueryStringWindow *>(FindWindowByClass(WC_QUERY_STRING));
|
||||
if (w != nullptr) w->editbox.orig = str;
|
||||
}
|
||||
|
||||
/**
|
||||
* Window used for asking the user a YES/NO question.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user