From c7e95d5b03bf7498c00596ed38f88d102d26b30f Mon Sep 17 00:00:00 2001 From: Jonathan G Rennison Date: Thu, 22 Feb 2024 23:34:52 +0000 Subject: [PATCH] Close graph windows when changing timekeeping mode --- src/settings.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/settings.cpp b/src/settings.cpp index 6375f7a8bb..cdd6adc620 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -1282,6 +1282,13 @@ static void ChangeTimekeepingUnits(int32_t) } UpdateTimeSettings(0); + CloseWindowByClass(WC_PAYMENT_RATES); + CloseWindowByClass(WC_COMPANY_VALUE); + CloseWindowByClass(WC_PERFORMANCE_HISTORY); + CloseWindowByClass(WC_DELIVERED_CARGO); + CloseWindowByClass(WC_OPERATING_PROFIT); + CloseWindowByClass(WC_INCOME_GRAPH); + CloseWindowByClass(WC_STATION_CARGO); } /**