From 18e567c168d26ed12a6703edc39c98adf9f6ff23 Mon Sep 17 00:00:00 2001 From: rubidium Date: Wed, 23 Jun 2010 14:56:17 +0000 Subject: (svn r20014) -Fix [FS#3881]: don't close the sort dropdown in the (original) vehicle list when there are no vehicles. That code is meant for the "actions" dropdown --- src/vehicle_gui.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/vehicle_gui.cpp') diff --git a/src/vehicle_gui.cpp b/src/vehicle_gui.cpp index f43f5b862..7d9e13e4a 100644 --- a/src/vehicle_gui.cpp +++ b/src/vehicle_gui.cpp @@ -1114,7 +1114,9 @@ public: this->BuildVehicleList(this->owner, GB(this->window_number, 16, 16), window_type); this->SortVehicleList(); - if (this->vehicles.Length() == 0) HideDropDownMenu(this); + if (this->vehicles.Length() == 0 && this->IsWidgetLowered(VLW_WIDGET_MANAGE_VEHICLES_DROPDOWN)) { + HideDropDownMenu(this); + } /* Hide the widgets that we will not use in this window * Some windows contains actions only fit for the owner */ -- cgit v1.2.3-54-g00ecf