Fixed crash exiting internal cells. Better starting camera position for external cells.

loadfix
cc9cii 10 years ago
parent a161ad3cd5
commit 7836ee9ab6

@ -134,8 +134,22 @@ void CSVRender::PagedWorldspaceWidget::mouseReleaseEvent (QMouseEvent *event)
}
}
void CSVRender::PagedWorldspaceWidget::mouseDoubleClickEvent (QMouseEvent *event)
{
if(event->button() == Qt::RightButton)
{
std::cout << "double clicked" << std::endl;
}
}
void CSVRender::PagedWorldspaceWidget::updateOverlay()
{
// better camera position at the start
if(getCamera()->getViewport() && getCamera()->getPosition().z < 1)
{
getCamera()->move(getCamera()->getDirection() * -6000);
}
Ogre::OverlayManager &overlayMgr = Ogre::OverlayManager::getSingleton();
Ogre::Overlay* overlay = overlayMgr.getByName("CellIDPanel");
if(overlay && !mTextOverlays.empty())

@ -82,6 +82,8 @@ namespace CSVRender
virtual void mouseReleaseEvent (QMouseEvent *event);
virtual void mouseDoubleClickEvent (QMouseEvent *event);
signals:
void cellSelectionChanged (const CSMWorld::CellSelection& selection);

@ -166,8 +166,6 @@ namespace CSVRender
{
if (mSceneMgr)
mSceneMgr->removeRenderQueueListener (mOverlaySystem);
delete mOverlaySystem;
}
if (mSceneMgr)

Loading…
Cancel
Save