mirror of https://github.com/OpenTTD/OpenTTD.git
Codechange: Use dynamic_cast with FindWindowById. (#12458)
Missed from 74e09ab
.
This commit is contained in:
parent
7e28605830
commit
1b127628cb
|
@ -83,7 +83,7 @@ void ShowScreenshotWindow()
|
|||
*/
|
||||
void SetScreenshotWindowVisibility(bool hide)
|
||||
{
|
||||
ScreenshotWindow *scw = (ScreenshotWindow *)FindWindowById(WC_SCREENSHOT, 0);
|
||||
ScreenshotWindow *scw = dynamic_cast<ScreenshotWindow *>(FindWindowById(WC_SCREENSHOT, 0));
|
||||
|
||||
if (scw == nullptr) return;
|
||||
|
||||
|
|
Loading…
Reference in New Issue