summaryrefslogtreecommitdiff
path: root/src/group_gui.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/group_gui.cpp')
-rw-r--r--src/group_gui.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/group_gui.cpp b/src/group_gui.cpp
index af2941527..8c1859764 100644
--- a/src/group_gui.cpp
+++ b/src/group_gui.cpp
@@ -680,7 +680,7 @@ public:
virtual void OnResize()
{
NWidgetCore *nwi = this->GetWidget<NWidgetCore>(WID_GL_LIST_GROUP);
- this->group_sb->SetCapacity(nwi->current_y / this->tiny_step_height);
+ this->group_sb->SetCapacityFromWidget(this, WID_GL_LIST_GROUP);
nwi->widget_data = (this->group_sb->GetCapacity() << MAT_ROW_START) + (1 << MAT_COL_START);
nwi = this->GetWidget<NWidgetCore>(WID_GL_LIST_VEHICLE);