summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/build_vehicle_gui.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/build_vehicle_gui.cpp b/src/build_vehicle_gui.cpp
index 4a0636788..ae787602b 100644
--- a/src/build_vehicle_gui.cpp
+++ b/src/build_vehicle_gui.cpp
@@ -1161,8 +1161,9 @@ struct BuildVehicleWindow : Window {
needed_height = max(needed_height, text_end - (int)nwi->pos_y + WD_FRAMERECT_BOTTOM);
}
if (needed_height != this->details_height) { // Details window are not high enough, enlarge them.
+ int resize = needed_height - this->details_height;
this->details_height = needed_height;
- this->ReInit();
+ this->ReInit(0, resize);
return;
}
}