mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-01-31 19:33:34 +00:00
(svn r13299) -Fix (r13286): Stations sort type isn't updated correctly
This commit is contained in:
parent
437d5d9798
commit
49a0bd7f90
@ -202,11 +202,7 @@ protected:
|
||||
/* Reset name sorter sort cache */
|
||||
this->last_station = NULL;
|
||||
|
||||
/* Display the current sort variant */
|
||||
this->widget[SLW_SORTDROPBTN].data = this->sorter_names[this->stations.SortType()];
|
||||
|
||||
/* Set the modified widgets dirty */
|
||||
this->InvalidateWidget(SLW_SORTDROPBTN);
|
||||
/* Set the modified widget dirty */
|
||||
this->InvalidateWidget(SLW_LIST);
|
||||
}
|
||||
|
||||
@ -274,6 +270,8 @@ public:
|
||||
this->stations.NeedResort();
|
||||
this->SortStationsList();
|
||||
|
||||
this->widget[SLW_SORTDROPBTN].data = this->sorter_names[this->stations.SortType()];
|
||||
|
||||
this->FindWindowPlacementAndResize(desc);
|
||||
}
|
||||
|
||||
@ -501,6 +499,10 @@ public:
|
||||
{
|
||||
if (this->stations.SortType() != index) {
|
||||
this->stations.SetSortType(index);
|
||||
|
||||
/* Display the current sort variant */
|
||||
this->widget[SLW_SORTDROPBTN].data = this->sorter_names[this->stations.SortType()];
|
||||
|
||||
this->SetDirty();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user