diff --git a/lang/american.txt b/lang/american.txt index f4cb93d9e6..ce83dad53f 100644 --- a/lang/american.txt +++ b/lang/american.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Name STR_SORT_BY_DROPDOWN_NAME :Name STR_SORT_BY_DATE :{BLACK}Date -STR_SORT_BY_UNSORTED :Unsorted STR_SORT_BY_NUMBER :Number STR_SORT_BY_PROFIT_LAST_YEAR :Profit last year STR_SORT_BY_PROFIT_THIS_YEAR :Profit this year diff --git a/lang/brazilian_portuguese.txt b/lang/brazilian_portuguese.txt index c1f7ffc4a3..4ee83a28b1 100644 --- a/lang/brazilian_portuguese.txt +++ b/lang/brazilian_portuguese.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nome STR_SORT_BY_DROPDOWN_NAME :Nome STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :Sem classificar STR_SORT_BY_NUMBER :Nmero STR_SORT_BY_PROFIT_LAST_YEAR :Lucros do ltimo ano STR_SORT_BY_PROFIT_THIS_YEAR :Lucros deste ano diff --git a/lang/catalan.txt b/lang/catalan.txt index f9686521a4..000ae03feb 100644 --- a/lang/catalan.txt +++ b/lang/catalan.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nom STR_SORT_BY_DROPDOWN_NAME :Nom STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :Sense ordre STR_SORT_BY_NUMBER :Nmero STR_SORT_BY_PROFIT_LAST_YEAR :Benef. darrer any STR_SORT_BY_PROFIT_THIS_YEAR :Benef. aquest any diff --git a/lang/czech.txt b/lang/czech.txt index 8a1384ec12..65c4d4aee8 100644 --- a/lang/czech.txt +++ b/lang/czech.txt @@ -426,7 +426,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Preprave STR_SORT_BY_NAME :{BLACK}Podle jmna STR_SORT_BY_DROPDOWN_NAME :jmna STR_SORT_BY_DATE :{BLACK}Podle data -STR_SORT_BY_UNSORTED :(neradit) STR_SORT_BY_NUMBER :cisla STR_SORT_BY_PROFIT_LAST_YEAR :hrubho zisku vloni STR_SORT_BY_PROFIT_THIS_YEAR :hrubho zisku letos diff --git a/lang/danish.txt b/lang/danish.txt index f69665f364..a141993c52 100644 --- a/lang/danish.txt +++ b/lang/danish.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Navn STR_SORT_BY_DROPDOWN_NAME :Navn STR_SORT_BY_DATE :{BLACK}Dato -STR_SORT_BY_UNSORTED :Usorteret STR_SORT_BY_NUMBER :Nummer STR_SORT_BY_PROFIT_LAST_YEAR :Profit sidste r STR_SORT_BY_PROFIT_THIS_YEAR :Profit dette r diff --git a/lang/dutch.txt b/lang/dutch.txt index cdb87a1a53..f1d312b5ca 100644 --- a/lang/dutch.txt +++ b/lang/dutch.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Vervoerd STR_SORT_BY_NAME :{BLACK}Naam STR_SORT_BY_DROPDOWN_NAME :Naam STR_SORT_BY_DATE :{BLACK}Datum -STR_SORT_BY_UNSORTED :Ongesorteerd STR_SORT_BY_NUMBER :Nummer STR_SORT_BY_PROFIT_LAST_YEAR :Winst vorig jaar STR_SORT_BY_PROFIT_THIS_YEAR :Winst dit jaar diff --git a/lang/english.txt b/lang/english.txt index f11c70a389..272a921093 100644 --- a/lang/english.txt +++ b/lang/english.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Name STR_SORT_BY_DROPDOWN_NAME :Name STR_SORT_BY_DATE :{BLACK}Date -STR_SORT_BY_UNSORTED :Unsorted STR_SORT_BY_NUMBER :Number STR_SORT_BY_PROFIT_LAST_YEAR :Profit last year STR_SORT_BY_PROFIT_THIS_YEAR :Profit this year diff --git a/lang/estonian.txt b/lang/estonian.txt index 84e099c208..acf29e5051 100644 --- a/lang/estonian.txt +++ b/lang/estonian.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nimi STR_SORT_BY_DROPDOWN_NAME :Nimi STR_SORT_BY_DATE :{BLACK}Kuupev -STR_SORT_BY_UNSORTED :Sorteerimata STR_SORT_BY_NUMBER :Number STR_SORT_BY_PROFIT_LAST_YEAR :Eelmise aasta kasum STR_SORT_BY_PROFIT_THIS_YEAR :Selle aasta kasum diff --git a/lang/finnish.txt b/lang/finnish.txt index ea29867c38..373561cad9 100644 --- a/lang/finnish.txt +++ b/lang/finnish.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Kuljetet STR_SORT_BY_NAME :{BLACK}Nimi STR_SORT_BY_DROPDOWN_NAME :Nimi STR_SORT_BY_DATE :{BLACK}Pivys -STR_SORT_BY_UNSORTED :Ei lajittelua STR_SORT_BY_NUMBER :Numero STR_SORT_BY_PROFIT_LAST_YEAR :Tuottoa viime vuonna STR_SORT_BY_PROFIT_THIS_YEAR :Tuottoa tn vuonna diff --git a/lang/french.txt b/lang/french.txt index 9ee222f669..bdbd544c5c 100644 --- a/lang/french.txt +++ b/lang/french.txt @@ -370,7 +370,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nom STR_SORT_BY_DROPDOWN_NAME :Nom STR_SORT_BY_DATE :{BLACK}Date -STR_SORT_BY_UNSORTED :Non tri STR_SORT_BY_NUMBER :Numro STR_SORT_BY_PROFIT_LAST_YEAR :Profit l'an dernier STR_SORT_BY_PROFIT_THIS_YEAR :Profit cette anne diff --git a/lang/galician.txt b/lang/galician.txt index 1f4269c016..c88503097b 100644 --- a/lang/galician.txt +++ b/lang/galician.txt @@ -366,7 +366,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nome STR_SORT_BY_DROPDOWN_NAME :Nome STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :Sen ordear STR_SORT_BY_NUMBER :Nmero STR_SORT_BY_PROFIT_LAST_YEAR :Beneficio ltimo ano STR_SORT_BY_PROFIT_THIS_YEAR :Beneficio este ano diff --git a/lang/german.txt b/lang/german.txt index 8d16d4bf39..e49afbc3fc 100644 --- a/lang/german.txt +++ b/lang/german.txt @@ -370,7 +370,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Name STR_SORT_BY_DROPDOWN_NAME :Name STR_SORT_BY_DATE :{BLACK}Datum -STR_SORT_BY_UNSORTED :Unsortiert STR_SORT_BY_NUMBER :Nummer STR_SORT_BY_PROFIT_LAST_YEAR :Profit letztes Jahr STR_SORT_BY_PROFIT_THIS_YEAR :Profit dieses Jahr diff --git a/lang/hungarian.txt b/lang/hungarian.txt index 04458abc0f..6886e6edcf 100644 --- a/lang/hungarian.txt +++ b/lang/hungarian.txt @@ -434,7 +434,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Elsz STR_SORT_BY_NAME :{BLACK}Nv STR_SORT_BY_DROPDOWN_NAME :Nv STR_SORT_BY_DATE :{BLACK}Dtum -STR_SORT_BY_UNSORTED :Rendezetlen STR_SORT_BY_NUMBER :Szm STR_SORT_BY_PROFIT_LAST_YEAR :Tavalyi profit STR_SORT_BY_PROFIT_THIS_YEAR :Idei profit diff --git a/lang/icelandic.txt b/lang/icelandic.txt index 52c719d763..c2f6b4958f 100644 --- a/lang/icelandic.txt +++ b/lang/icelandic.txt @@ -370,7 +370,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Flutt STR_SORT_BY_NAME :{BLACK}Nafn STR_SORT_BY_DROPDOWN_NAME :Nafn STR_SORT_BY_DATE :{BLACK}Dagsetning -STR_SORT_BY_UNSORTED :flokka STR_SORT_BY_NUMBER :Nmer STR_SORT_BY_PROFIT_LAST_YEAR :Hagnaur sasta rs STR_SORT_BY_PROFIT_THIS_YEAR :Hagnaur essa rs diff --git a/lang/italian.txt b/lang/italian.txt index 411e88f544..3524b9c699 100644 --- a/lang/italian.txt +++ b/lang/italian.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Trasport STR_SORT_BY_NAME :{BLACK}Nome STR_SORT_BY_DROPDOWN_NAME :Nome STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :Nessun ordine STR_SORT_BY_NUMBER :Numero STR_SORT_BY_PROFIT_LAST_YEAR :Profitto dell'anno scorso STR_SORT_BY_PROFIT_THIS_YEAR :Profitto di quest'anno diff --git a/lang/norwegian.txt b/lang/norwegian.txt index 01a12b2ba6..9b84932966 100644 --- a/lang/norwegian.txt +++ b/lang/norwegian.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Navn STR_SORT_BY_DROPDOWN_NAME :Navn STR_SORT_BY_DATE :{BLACK}Dato -STR_SORT_BY_UNSORTED :Usortert STR_SORT_BY_NUMBER :Nummer STR_SORT_BY_PROFIT_LAST_YEAR :Fortjeneste forrige r STR_SORT_BY_PROFIT_THIS_YEAR :Fortjeneste innevrende r diff --git a/lang/polish.txt b/lang/polish.txt index e4c1e1e56d..0a14c6d265 100644 --- a/lang/polish.txt +++ b/lang/polish.txt @@ -422,7 +422,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Przetran STR_SORT_BY_NAME :{BLACK}Nazwa STR_SORT_BY_DROPDOWN_NAME :Nazwa STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :Nieposortowane STR_SORT_BY_NUMBER :Numer STR_SORT_BY_PROFIT_LAST_YEAR :Zysk w ostatnim roku STR_SORT_BY_PROFIT_THIS_YEAR :Zysk w tym roku diff --git a/lang/portuguese.txt b/lang/portuguese.txt index 52e2167be8..0bd3f8443c 100644 --- a/lang/portuguese.txt +++ b/lang/portuguese.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nome STR_SORT_BY_DROPDOWN_NAME :Nome STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :No ordenado STR_SORT_BY_NUMBER :Nmero STR_SORT_BY_PROFIT_LAST_YEAR :Lucros do ltimo ano STR_SORT_BY_PROFIT_THIS_YEAR :Lucros deste ano diff --git a/lang/romanian.txt b/lang/romanian.txt index f57c14feda..f670344c13 100644 --- a/lang/romanian.txt +++ b/lang/romanian.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nume STR_SORT_BY_DROPDOWN_NAME :Nume STR_SORT_BY_DATE :{BLACK}Dat -STR_SORT_BY_UNSORTED :Neordonat STR_SORT_BY_NUMBER :Numar STR_SORT_BY_PROFIT_LAST_YEAR :Profit anul trecut STR_SORT_BY_PROFIT_THIS_YEAR :Profit anul acesta diff --git a/lang/slovak.txt b/lang/slovak.txt index 7f9ecdc25d..8403e8372f 100644 --- a/lang/slovak.txt +++ b/lang/slovak.txt @@ -433,7 +433,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Preprave STR_SORT_BY_NAME :{BLACK}Nazov STR_SORT_BY_DROPDOWN_NAME :Nazov STR_SORT_BY_DATE :{BLACK}Datum -STR_SORT_BY_UNSORTED :Neusporiadane STR_SORT_BY_NUMBER :Cislo STR_SORT_BY_PROFIT_LAST_YEAR :Zisk v poslednom roku STR_SORT_BY_PROFIT_THIS_YEAR :Zisk v tomto roku diff --git a/lang/spanish.txt b/lang/spanish.txt index c6f76edca0..43dc89a59e 100644 --- a/lang/spanish.txt +++ b/lang/spanish.txt @@ -370,7 +370,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Nombre STR_SORT_BY_DROPDOWN_NAME :Nombre STR_SORT_BY_DATE :{BLACK}Fecha -STR_SORT_BY_UNSORTED :Sin ordenar STR_SORT_BY_NUMBER :Nmero STR_SORT_BY_PROFIT_LAST_YEAR :Beneficio ao pasado STR_SORT_BY_PROFIT_THIS_YEAR :Beneficio ao actual diff --git a/lang/swedish.txt b/lang/swedish.txt index 14bc2443c9..285d6f59fa 100644 --- a/lang/swedish.txt +++ b/lang/swedish.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Namn STR_SORT_BY_DROPDOWN_NAME :Namn STR_SORT_BY_DATE :{BLACK}Datum -STR_SORT_BY_UNSORTED :Osorterat STR_SORT_BY_NUMBER :Nummer STR_SORT_BY_PROFIT_LAST_YEAR :Vinst frra ret STR_SORT_BY_PROFIT_THIS_YEAR :Vinst i r diff --git a/lang/turkish.txt b/lang/turkish.txt index 08d247e289..1e1fe62330 100644 --- a/lang/turkish.txt +++ b/lang/turkish.txt @@ -369,7 +369,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Tasinan STR_SORT_BY_NAME :{BLACK}isim STR_SORT_BY_DROPDOWN_NAME :isim STR_SORT_BY_DATE :{BLACK}Tarih -STR_SORT_BY_UNSORTED :Siralanmamis STR_SORT_BY_NUMBER :Numara STR_SORT_BY_PROFIT_LAST_YEAR :Geen seneki kar STR_SORT_BY_PROFIT_THIS_YEAR :Bu seneki kar diff --git a/lang/unfinished/latvian.txt b/lang/unfinished/latvian.txt index 03fccda66f..b69984fa93 100644 --- a/lang/unfinished/latvian.txt +++ b/lang/unfinished/latvian.txt @@ -337,7 +337,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Transpor STR_SORT_BY_NAME :{BLACK}Va'rda STR_SORT_BY_DROPDOWN_NAME :Va'rds STR_SORT_BY_DATE :{BLACK}Datums -STR_SORT_BY_UNSORTED :Nesaka'rtots STR_SORT_BY_NUMBER :Nummurs STR_SORT_BY_PROFIT_LAST_YEAR :Paga'jus'a' gada iena'kums STR_SORT_BY_PROFIT_THIS_YEAR :S'i' gada iena'kums diff --git a/lang/unfinished/lithuanian.txt b/lang/unfinished/lithuanian.txt index 47460f5318..2a8ae739e4 100644 --- a/lang/unfinished/lithuanian.txt +++ b/lang/unfinished/lithuanian.txt @@ -358,7 +358,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Pervezim STR_SORT_BY_NAME :{BLACK}Varda STR_SORT_BY_DROPDOWN_NAME :Varda STR_SORT_BY_DATE :{BLACK}Data -STR_SORT_BY_UNSORTED :Nerikiuota STR_SORT_BY_NUMBER :Kieki STR_SORT_BY_PROFIT_LAST_YEAR :Praeitu metu pelna STR_SORT_BY_PROFIT_THIS_YEAR :Siu metu pelna diff --git a/lang/unfinished/slovenian.txt b/lang/unfinished/slovenian.txt index 324616a2be..d45a91d088 100644 --- a/lang/unfinished/slovenian.txt +++ b/lang/unfinished/slovenian.txt @@ -363,7 +363,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}Prenesen STR_SORT_BY_NAME :{BLACK}Ime STR_SORT_BY_DROPDOWN_NAME :Ime STR_SORT_BY_DATE :{BLACK}Datum -STR_SORT_BY_UNSORTED :Nesortirano STR_SORT_BY_NUMBER :Stevilo STR_SORT_BY_PROFIT_LAST_YEAR :Profit zadnje leto STR_SORT_BY_PROFIT_THIS_YEAR :Profit to leto diff --git a/lang/unfinished/ukrainian.txt b/lang/unfinished/ukrainian.txt index 0a318d4097..8c3362b580 100644 --- a/lang/unfinished/ukrainian.txt +++ b/lang/unfinished/ukrainian.txt @@ -370,7 +370,6 @@ STR_SORT_BY_TRANSPORTED :{BLACK}за п STR_SORT_BY_NAME :{BLACK}за назвою STR_SORT_BY_DROPDOWN_NAME :Назва STR_SORT_BY_DATE :{BLACK}за датою -STR_SORT_BY_UNSORTED :не треба STR_SORT_BY_NUMBER :за номером STR_SORT_BY_PROFIT_LAST_YEAR :за прибутком минулого року STR_SORT_BY_PROFIT_THIS_YEAR :за прибутком цього року diff --git a/vehicle_gui.c b/vehicle_gui.c index 895581a6d4..ed47531097 100644 --- a/vehicle_gui.c +++ b/vehicle_gui.c @@ -40,7 +40,6 @@ static RailType _railtype_selected_in_replace_gui; typedef int CDECL VehicleSortListingTypeFunction(const void*, const void*); -static VehicleSortListingTypeFunction VehicleUnsortedSorter; static VehicleSortListingTypeFunction VehicleNumberSorter; static VehicleSortListingTypeFunction VehicleNameSorter; static VehicleSortListingTypeFunction VehicleAgeSorter; @@ -53,7 +52,6 @@ static VehicleSortListingTypeFunction VehicleModelSorter; static VehicleSortListingTypeFunction VehicleValueSorter; static VehicleSortListingTypeFunction* const _vehicle_sorter[] = { - &VehicleUnsortedSorter, &VehicleNumberSorter, &VehicleNameSorter, &VehicleAgeSorter, @@ -66,8 +64,7 @@ static VehicleSortListingTypeFunction* const _vehicle_sorter[] = { &VehicleValueSorter, }; -const StringID _vehicle_sort_listing[] = { - STR_SORT_BY_UNSORTED, +static const StringID _vehicle_sort_listing[] = { STR_SORT_BY_NUMBER, STR_SORT_BY_DROPDOWN_NAME, STR_SORT_BY_AGE, @@ -295,10 +292,6 @@ int ShowAdditionalText(int x, int y, int w, EngineID engine) * 3. (uint32)_internal_name_sorter_id: default StringID of the vehicle when no name is set. eg * STR_SV_TRAIN_NAME for trains or STR_SV_AIRCRAFT_NAME for aircraft */ -static int CDECL VehicleUnsortedSorter(const void *a, const void *b) -{ - return (*(const Vehicle**)a)->index - (*(const Vehicle**)b)->index; -} // if the sorting criteria had the same value, sort vehicle by unitnumber #define VEHICLEUNITNUMBERSORTER(r, a, b) {if (r == 0) {r = a->unitnumber - b->unitnumber;}} @@ -1236,9 +1229,6 @@ void PlayerVehWndProc(Window *w, WindowEvent *e) SortVehicleList(vl); SetVScrollCount(w, vl->list_length); - // disable 'Sort By' tooltip on Unsorted sorting criteria - if (vl->sort_type == SORT_BY_UNSORTED) SETBIT(w->disabled_state, 3); - /* draw the widgets */ switch (window_type) { case VLW_SHARED_ORDERS: @@ -1456,8 +1446,6 @@ void PlayerVehWndProc(Window *w, WindowEvent *e) case VEH_Aircraft: _sorting.aircraft.criteria = vl->sort_type; break; default: NOT_REACHED(); break; } - // enable 'Sort By' if a sorter criteria is chosen - if (vl->sort_type != SORT_BY_UNSORTED) CLRBIT(w->disabled_state, 3); } SetWindowDirty(w); break; diff --git a/vehicle_gui.h b/vehicle_gui.h index 1b2bc6a1a0..d9aa78c1d0 100644 --- a/vehicle_gui.h +++ b/vehicle_gui.h @@ -18,8 +18,6 @@ void RebuildVehicleLists(void); void ResortVehicleLists(void); #define PERIODIC_RESORT_DAYS 10 -#define SORT_BY_UNSORTED 0 -extern const StringID _vehicle_sort_listing[]; typedef struct Listing { bool order; // Ascending/descending?