From 4cae19175e79c5e446bfddbe377ad26821bfa1cf Mon Sep 17 00:00:00 2001 From: smatz Date: Tue, 15 Jun 2010 22:48:50 +0000 Subject: (svn r19990) -Fix: owner of the Waypoint View window wasn't properly set --- src/waypoint_gui.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/waypoint_gui.cpp b/src/waypoint_gui.cpp index 3e7b3d44b..430a1cf37 100644 --- a/src/waypoint_gui.cpp +++ b/src/waypoint_gui.cpp @@ -44,8 +44,6 @@ public: this->wp = Waypoint::Get(window_number); this->vt = (wp->string_id == STR_SV_STNAME_WAYPOINT) ? VEH_TRAIN : VEH_SHIP; - if (this->wp->owner != OWNER_NONE) this->owner = this->wp->owner; - this->CreateNestedTree(desc); if (this->vt == VEH_TRAIN) { this->GetWidget(WAYPVW_SHOW_VEHICLES)->SetDataTip(STR_TRAIN, STR_STATION_VIEW_SCHEDULED_TRAINS_TOOLTIP); @@ -54,7 +52,9 @@ public: } this->FinishInitNested(desc, window_number); + if (this->wp->owner != OWNER_NONE) this->owner = this->wp->owner; this->flags4 |= WF_DISABLE_VP_SCROLL; + NWidgetViewport *nvp = this->GetWidget(WAYPVW_VIEWPORT); nvp->InitializeViewport(this, this->wp->xy, ZOOM_LVL_MIN); -- cgit v1.2.3-70-g09d2