From c2b070f097dcabcff3321f711394f403037bc4a0 Mon Sep 17 00:00:00 2001 From: Marek Kochanowicz Date: Thu, 1 May 2014 19:17:33 +0200 Subject: [PATCH] trying to do it right. --- apps/opencs/view/world/scenesubview.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/apps/opencs/view/world/scenesubview.cpp b/apps/opencs/view/world/scenesubview.cpp index 45cd11618..f3807e4e9 100644 --- a/apps/opencs/view/world/scenesubview.cpp +++ b/apps/opencs/view/world/scenesubview.cpp @@ -143,9 +143,9 @@ void CSVWorld::SceneSubView::changeToPaged (const std::vector< CSMWorld::Univers mLayout->removeWidget(mScene); delete mScene; - delete mToolbar; + setUniversalId(CSMWorld::UniversalId(CSMWorld::UniversalId::Type_Cell, "sys::default")); mToolbar = new SceneToolbar (48+6, this); CSVRender::PagedWorldspaceWidget* widget = new CSVRender::PagedWorldspaceWidget (this, mDocument); @@ -184,6 +184,7 @@ void CSVWorld::SceneSubView::changeToUnpaged (const std::vector< CSMWorld::Unive mToolbar = new SceneToolbar (48+6, this); CSVRender::UnpagedWorldspaceWidget* widget = new CSVRender::UnpagedWorldspaceWidget (data.begin()->getId(), mDocument, this); + setUniversalId(*(data.begin())); mScene = widget;