summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authoralberth <alberth@openttd.org>2009-12-30 08:40:05 +0000
committeralberth <alberth@openttd.org>2009-12-30 08:40:05 +0000
commitba3ef1a2d5fb1f0eda4ea76ad8a1d46ef380f372 (patch)
tree817d6d0a50e8f32422a402bf6adfae0a158dadf1 /src
parent2ab3e5ab400f9152f7a7828b1d505ec41205796e (diff)
downloadopenttd-ba3ef1a2d5fb1f0eda4ea76ad8a1d46ef380f372.tar.xz
(svn r18664) -Fix [FS#3449]: Unshade shaded finances window when toggling size.
Diffstat (limited to 'src')
-rw-r--r--src/company_gui.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/company_gui.cpp b/src/company_gui.cpp
index 4cb23cfbc..67c6a9ea4 100644
--- a/src/company_gui.cpp
+++ b/src/company_gui.cpp
@@ -437,7 +437,13 @@ struct CompanyFinancesWindow : Window {
case CFW_TOGGLE_SIZE: // toggle size
this->small = !this->small;
this->SetupWidgets();
- this->ReInit();
+ if (this->IsShaded()) {
+ /* Finances window is not resizable, so size hints given during unshading have no effect
+ * on the changed appearance of the window. */
+ this->SetShaded(false);
+ } else {
+ this->ReInit();
+ }
break;
case CFW_INCREASE_LOAN: // increase loan