1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2025-12-22 15:23:01 +01:00

Prevent closing object selection window when selection is invalid (#23487)

* Prevent closing object selection window when selection is invalid

* Ride window: remove superfluous virtual keyword from event signatures

* Amend changelog
This commit is contained in:
Aaron van Geffen
2024-12-29 23:15:26 +01:00
committed by GitHub
parent fef568c7c8
commit 25ac4cf5d6
5 changed files with 35 additions and 18 deletions

View File

@@ -227,6 +227,12 @@ void WindowSetWindowLimit(int32_t value)
*/
void WindowClose(WindowBase& w)
{
if (!w.CanClose())
{
// Something's preventing this window from closing -- bail out early
return;
}
w.OnClose();
// Remove viewport