Codechange: use int32_t instead of uint16_t for scroll bar position/size/capacity
(cherry picked from commit d09b5aaeba
)
# Conflicts:
# src/newgrf_debug_gui.cpp
# src/newgrf_gui.cpp
# src/widget_type.h
This commit is contained in:

committed by
Jonathan G Rennison

parent
2219b8e378
commit
5d8e40cad4
@@ -887,7 +887,7 @@ struct ExcludingCargoBaseGraphWindow : BaseGraphWindow {
|
||||
}
|
||||
|
||||
case WID_ECBG_MATRIX: {
|
||||
uint row = this->vscroll->GetScrolledRowFromWidget(pt.y, this, WID_ECBG_MATRIX);
|
||||
int32_t row = this->vscroll->GetScrolledRowFromWidget(pt.y, this, WID_ECBG_MATRIX);
|
||||
if (row >= this->vscroll->GetCount()) return;
|
||||
|
||||
for (const CargoSpec *cs : _sorted_standard_cargo_specs) {
|
||||
@@ -2027,7 +2027,7 @@ struct StationCargoGraphWindow final : BaseGraphWindow {
|
||||
}
|
||||
|
||||
case WID_SCG_MATRIX: {
|
||||
uint row = this->vscroll->GetScrolledRowFromWidget(pt.y, this, WID_SCG_MATRIX);
|
||||
int32_t row = this->vscroll->GetScrolledRowFromWidget(pt.y, this, WID_SCG_MATRIX);
|
||||
if (row >= this->vscroll->GetCount()) return;
|
||||
|
||||
for (const CargoSpec *cs : _sorted_standard_cargo_specs) {
|
||||
|
Reference in New Issue
Block a user