Codechange: Move to GetWidgetString for help window. (#13733)

This commit is contained in:
Peter Nelson 2025-03-03 23:32:08 +00:00 committed by GitHub
parent c9624cef7c
commit ed65fea7dd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -76,11 +76,13 @@ struct GameManualTextfileWindow : public TextfileWindow {
this->OnClick({ 0, 0 }, WID_TF_WRAPTEXT, 1);
}
void SetStringParameters(WidgetID widget) const override
std::string GetWidgetString(WidgetID widget, StringID stringid) const override
{
if (widget == WID_TF_CAPTION) {
SetDParamStr(0, this->filename);
return GetString(stringid, this->filename);
}
return this->Window::GetWidgetString(widget, stringid);
}
void AfterLoadText() override