(svn r165) -Feature: Option to sort vehicles in vehicle-list window by different criteria. Total independent sort for all types and players. Periodic resort of list every 10 TTD days. Thank you for your graphical inspiration follow and buxo (since none of you provided any code).

-Fix: Sorter icon pointing down 'v' sorts in every window lowest value first, '^' highest value first
-CodeChange: move Dropdownlist from settings_gui.c to widget.c. More in place there.
This commit is contained in:
darkvater
2004-09-06 18:15:13 +00:00
parent df1397a47e
commit bf0652d3fc
28 changed files with 1282 additions and 612 deletions

View File

@@ -852,6 +852,7 @@ int32 CmdBuildShip(int x, int y, uint32 flags, uint32 p1, uint32 p2)
VehiclePositionChanged(v);
InvalidateWindow(WC_VEHICLE_DEPOT, v->tile);
_vehicle_sort_dirty[VEHSHIP] = true; // build a ship
InvalidateWindow(WC_SHIPS_LIST, v->owner);
InvalidateWindow(WC_COMPANY, v->owner);
}
@@ -875,6 +876,7 @@ int32 CmdSellShip(int x, int y, uint32 flags, uint32 p1, uint32 p2)
if (flags & DC_EXEC) {
InvalidateWindow(WC_VEHICLE_DEPOT, v->tile);
_vehicle_sort_dirty[VEHSHIP] = true; // sell a ship
InvalidateWindow(WC_SHIPS_LIST, v->owner);
InvalidateWindow(WC_COMPANY, v->owner);
DeleteWindowById(WC_VEHICLE_VIEW, v->index);