1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-04-12 08:06:44 +00:00

More cleanup.

This commit is contained in:
cc9cii 2014-10-27 12:09:20 +11:00
parent c2c33eac0f
commit 6c8320a638
2 changed files with 10 additions and 6 deletions

View file

@ -297,7 +297,7 @@ void CSVRender::PagedWorldspaceWidget::mouseDoubleClickEvent (QMouseEvent *event
// debug drawer. Hence only the first subview that creates the debug drawer // debug drawer. Hence only the first subview that creates the debug drawer
// can view the debug lines. Will need to keep a map in OEngine if multiple // can view the debug lines. Will need to keep a map in OEngine if multiple
// subviews are to be supported. // subviews are to be supported.
//CSVWorld::PhysicsSystem::instance()->setSceneManager(getSceneManager()); CSVWorld::PhysicsSystem::instance()->setSceneManager(getSceneManager());
CSVWorld::PhysicsSystem::instance()->toggleDebugRendering(); CSVWorld::PhysicsSystem::instance()->toggleDebugRendering();
flagAsModified(); flagAsModified();
} }
@ -444,7 +444,11 @@ CSVRender::PagedWorldspaceWidget::~PagedWorldspaceWidget()
for(;iter != mSelectedEntities.end(); ++iter) for(;iter != mSelectedEntities.end(); ++iter)
{ {
removeHitPoint(getSceneManager(), iter->first); removeHitPoint(getSceneManager(), iter->first);
if(getSceneManager()->hasSceneNode(iter->first))
{
Ogre::SceneNode *scene = getSceneManager()->getSceneNode(iter->first); Ogre::SceneNode *scene = getSceneManager()->getSceneNode(iter->first);
if(scene) if(scene)
{ {
scene->removeAndDestroyAllChildren(); scene->removeAndDestroyAllChildren();
@ -452,6 +456,7 @@ CSVRender::PagedWorldspaceWidget::~PagedWorldspaceWidget()
} }
} }
} }
}
void CSVRender::PagedWorldspaceWidget::useViewHint (const std::string& hint) void CSVRender::PagedWorldspaceWidget::useViewHint (const std::string& hint)
{ {

View file

@ -61,7 +61,6 @@ namespace CSVWorld
private: private:
void initDebug();
void updateSelectionHighlight(std::string sceneNode, const Ogre::Vector3 &position); void updateSelectionHighlight(std::string sceneNode, const Ogre::Vector3 &position);
}; };
} }