(svn r18126) -Codechange: remove duplicate (since r18119) scrollbar capacity/matrix initialisation

This commit is contained in:
rubidium
2009-11-16 20:34:57 +00:00
parent 242bf23835
commit a13fd6ddce
18 changed files with 4 additions and 75 deletions

View File

@@ -206,23 +206,6 @@ public:
this->CreateNestedTree(desc);
this->vehicle_type = (VehicleType)GB(window_number, 11, 5);
switch (this->vehicle_type) {
default: NOT_REACHED();
case VEH_TRAIN:
case VEH_ROAD:
this->vscroll2.SetCapacity(9);
this->vscroll.SetCapacity(6);
break;
case VEH_SHIP:
case VEH_AIRCRAFT:
this->vscroll2.SetCapacity(9);
this->vscroll.SetCapacity(4);
break;
}
this->GetWidget<NWidgetCore>(GRP_WIDGET_LIST_GROUP)->widget_data = (this->vscroll2.GetCapacity() << MAT_ROW_START) + (1 << MAT_COL_START);
this->GetWidget<NWidgetCore>(GRP_WIDGET_LIST_VEHICLE)->widget_data = (this->vscroll.GetCapacity() << MAT_ROW_START) + (1 << MAT_COL_START);
switch (this->vehicle_type) {
default: NOT_REACHED();
case VEH_TRAIN: this->sorting = &_sorting.train; break;