mirror of https://github.com/OpenTTD/OpenTTD
(svn r1326) fixed compiler warnings in vehicle_gui.c and widget.c
parent
efc2702491
commit
6a6cbdd9b4
|
@ -526,7 +526,7 @@ static void DrawEngineArrayInReplaceWindow(Window *w, int x, int y, int x2, int
|
|||
byte cargo;
|
||||
EngineInfo *info;
|
||||
|
||||
if ( selected_id[0] >= ROAD_ENGINES_INDEX && selected_id[0] <= SHIP_ENGINES_INDEX )
|
||||
if ( selected_id[0] >= ROAD_ENGINES_INDEX && selected_id[0] <= SHIP_ENGINES_INDEX ) {
|
||||
cargo = RoadVehInfo(selected_id[0])->cargo_type;
|
||||
|
||||
do {
|
||||
|
@ -549,7 +549,7 @@ static void DrawEngineArrayInReplaceWindow(Window *w, int x, int y, int x2, int
|
|||
sel[0]--;
|
||||
}
|
||||
} while (++engine_id, ++e,--num);
|
||||
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -563,7 +563,6 @@ static void DrawEngineArrayInReplaceWindow(Window *w, int x, int y, int x2, int
|
|||
if ( selected_id[0] != -1 ) {
|
||||
cargo = ShipVehInfo(selected_id[0])->cargo_type;
|
||||
refittable = ShipVehInfo(selected_id[0])->refittable;
|
||||
}
|
||||
|
||||
do {
|
||||
info = &_engine_info[engine_id];
|
||||
|
@ -586,6 +585,7 @@ static void DrawEngineArrayInReplaceWindow(Window *w, int x, int y, int x2, int
|
|||
sel[0]--;
|
||||
}
|
||||
} while (++engine_id, ++e,--num);
|
||||
}
|
||||
break;
|
||||
} //end of ship
|
||||
|
||||
|
@ -933,6 +933,7 @@ void ShowReplaceVehicleWindow(byte vehicletype)
|
|||
w->vscroll.cap = 4;
|
||||
WP(w,replaceveh_d).line_height = 24;
|
||||
break;
|
||||
default: return;
|
||||
}
|
||||
WP(w,replaceveh_d).vehicletype = vehicletype;
|
||||
w->vscroll2.cap = w->vscroll.cap; // these two are always the same
|
||||
|
|
Loading…
Reference in New Issue