summaryrefslogtreecommitdiff
path: root/src/object_gui.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/object_gui.cpp')
-rw-r--r--src/object_gui.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/object_gui.cpp b/src/object_gui.cpp
index b27388313..e4287c7ac 100644
--- a/src/object_gui.cpp
+++ b/src/object_gui.cpp
@@ -75,14 +75,12 @@ public:
BuildObjectWindow(WindowDesc *desc, Window *w) : PickerWindowBase(desc, w), info_height(1)
{
this->CreateNestedTree();
-
this->vscroll = this->GetScrollbar(WID_BO_SCROLLBAR);
- this->vscroll->SetCapacity(5);
+ this->FinishInitNested(0);
+
this->vscroll->SetPosition(0);
this->vscroll->SetCount(ObjectClass::GetUIClassCount());
- this->FinishInitNested(0);
-
if (this->CanRestoreSelectedObject()) {
this->SelectOtherObject(_selected_object_index);
} else {