diff options
-rw-r--r-- | src/network/network_gui.cpp | 1 | ||||
-rw-r--r-- | src/object_gui.cpp | 6 |
2 files changed, 2 insertions, 5 deletions
diff --git a/src/network/network_gui.cpp b/src/network/network_gui.cpp index 1760030bb..e4af9d5b9 100644 --- a/src/network/network_gui.cpp +++ b/src/network/network_gui.cpp @@ -1354,7 +1354,6 @@ struct NetworkLobbyWindow : public Window { this->CreateNestedTree(); this->vscroll = this->GetScrollbar(WID_NL_SCROLLBAR); this->FinishInitNested(WN_NETWORK_WINDOW_LOBBY); - this->OnResize(); } CompanyID NetworkLobbyFindCompanyIndex(byte pos) const 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 { |