From dfe5dad5f68250ec67a3cb5e69bc7f9f58f9a58c Mon Sep 17 00:00:00 2001 From: rubidium Date: Sun, 22 Mar 2009 11:06:25 +0000 Subject: (svn r15807) -Codechange: let the build vehicle gui helper function pass around left and right instead of only left and assuming infinite width. --- src/autoreplace_gui.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/autoreplace_gui.cpp') diff --git a/src/autoreplace_gui.cpp b/src/autoreplace_gui.cpp index a5fdda7c9..b8782f6c6 100644 --- a/src/autoreplace_gui.cpp +++ b/src/autoreplace_gui.cpp @@ -327,7 +327,7 @@ public: /* Also draw the details if an engine is selected */ if (this->sel_engine[i] != INVALID_ENGINE) { const Widget *wi = &this->widget[i == 0 ? RVW_WIDGET_LEFT_DETAILS : RVW_WIDGET_RIGHT_DETAILS]; - int text_end = DrawVehiclePurchaseInfo(wi->left + 2, wi->top + 1, wi->right - wi->left - 2, this->sel_engine[i]); + int text_end = DrawVehiclePurchaseInfo(wi->left + 2, wi->right - 2, wi->top + 1, this->sel_engine[i]); if (text_end > wi->bottom) { this->SetDirty(); -- cgit v1.2.3-54-g00ecf