(svn r26811) -Fix[FS#6108]: Fixed spelling error in widget name.
This commit is contained in:
@@ -60,7 +60,7 @@ static const NWidgetPart _nested_build_vehicle_widgets[] = {
|
||||
NWidget(WWT_PANEL, COLOUR_GREY),
|
||||
NWidget(NWID_VERTICAL),
|
||||
NWidget(NWID_HORIZONTAL),
|
||||
NWidget(WWT_PUSHTXTBTN, COLOUR_GREY, WID_BV_SORT_ASSENDING_DESCENDING), SetDataTip(STR_BUTTON_SORT_BY, STR_TOOLTIP_SORT_ORDER),
|
||||
NWidget(WWT_PUSHTXTBTN, COLOUR_GREY, WID_BV_SORT_ASCENDING_DESCENDING), SetDataTip(STR_BUTTON_SORT_BY, STR_TOOLTIP_SORT_ORDER),
|
||||
NWidget(WWT_DROPDOWN, COLOUR_GREY, WID_BV_SORT_DROPDOWN), SetResize(1, 0), SetFill(1, 0), SetDataTip(STR_JUST_STRING, STR_TOOLTIP_SORT_CRITERIA),
|
||||
EndContainer(),
|
||||
NWidget(NWID_HORIZONTAL),
|
||||
@@ -1262,7 +1262,7 @@ struct BuildVehicleWindow : Window {
|
||||
void OnClick(Point pt, int widget, int click_count)
|
||||
{
|
||||
switch (widget) {
|
||||
case WID_BV_SORT_ASSENDING_DESCENDING:
|
||||
case WID_BV_SORT_ASCENDING_DESCENDING:
|
||||
this->descending_sort_order ^= true;
|
||||
_engine_sort_last_order[this->vehicle_type] = this->descending_sort_order;
|
||||
this->eng_list.ForceRebuild();
|
||||
@@ -1389,7 +1389,7 @@ struct BuildVehicleWindow : Window {
|
||||
size->height = this->details_height;
|
||||
break;
|
||||
|
||||
case WID_BV_SORT_ASSENDING_DESCENDING: {
|
||||
case WID_BV_SORT_ASCENDING_DESCENDING: {
|
||||
Dimension d = GetStringBoundingBox(this->GetWidget<NWidgetCore>(widget)->widget_data);
|
||||
d.width += padding.width + WD_SORTBUTTON_ARROW_WIDTH * 2; // Doubled since the string is centred and it also looks better.
|
||||
d.height += padding.height;
|
||||
@@ -1413,8 +1413,8 @@ struct BuildVehicleWindow : Window {
|
||||
DrawEngineList(this->vehicle_type, r.left + WD_FRAMERECT_LEFT, r.right - WD_FRAMERECT_RIGHT, r.top + WD_FRAMERECT_TOP, &this->eng_list, this->vscroll->GetPosition(), min(this->vscroll->GetPosition() + this->vscroll->GetCapacity(), this->eng_list.Length()), this->sel_engine, false, DEFAULT_GROUP);
|
||||
break;
|
||||
|
||||
case WID_BV_SORT_ASSENDING_DESCENDING:
|
||||
this->DrawSortButtonState(WID_BV_SORT_ASSENDING_DESCENDING, this->descending_sort_order ? SBS_DOWN : SBS_UP);
|
||||
case WID_BV_SORT_ASCENDING_DESCENDING:
|
||||
this->DrawSortButtonState(WID_BV_SORT_ASCENDING_DESCENDING, this->descending_sort_order ? SBS_DOWN : SBS_UP);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user