#3426 Fix missing update of well targets when view is scaled

This commit is contained in:
Jacob Støren 2018-10-02 16:29:58 +02:00
parent d9e8537974
commit e3c7b4ffa4
4 changed files with 19 additions and 1 deletions

View File

@ -631,6 +631,17 @@ PdmUiSelectionVisualizer3d::~PdmUiSelectionVisualizer3d()
} }
} }
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void PdmUiSelectionVisualizer3d::updateVisibleEditors()
{
for (auto editor: m_active3DEditors)
{
if (editor) editor->updateUi();
}
}
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------
/// ///
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------

View File

@ -229,6 +229,8 @@ class PdmUiSelectionVisualizer3d : public QObject, caf::SelectionChangedReceiver
public: public:
PdmUiSelectionVisualizer3d(caf::Viewer* ownerViewer); PdmUiSelectionVisualizer3d(caf::Viewer* ownerViewer);
~PdmUiSelectionVisualizer3d(); ~PdmUiSelectionVisualizer3d();
void updateVisibleEditors();
protected: protected:
virtual void onSelectionManagerSelectionChanged( const std::set<int>& changedSelectionLevels ) override; virtual void onSelectionManagerSelectionChanged( const std::set<int>& changedSelectionLevels ) override;

View File

@ -187,7 +187,7 @@ RiuViewer::RiuViewer(const QGLFormat& format, QWidget* parent)
m_windowEdgeAxisOverlay = new RivWindowEdgeAxesOverlayItem(standardFont); m_windowEdgeAxisOverlay = new RivWindowEdgeAxesOverlayItem(standardFont);
m_showWindowEdgeAxes = false; m_showWindowEdgeAxes = false;
new caf::PdmUiSelectionVisualizer3d(this); m_selectionVisualizerManager = new caf::PdmUiSelectionVisualizer3d(this);
} }
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------
@ -834,6 +834,8 @@ void RiuViewer::updateGridBoxData(double scaleZ,
m_gridBoxGenerator->setGridBoxDomainCoordBoundingBox(domainCoordBoundingBox); m_gridBoxGenerator->setGridBoxDomainCoordBoundingBox(domainCoordBoundingBox);
m_gridBoxGenerator->createGridBoxParts(); m_gridBoxGenerator->createGridBoxParts();
m_selectionVisualizerManager->updateVisibleEditors();
} }
//-------------------------------------------------------------------------------------------------- //--------------------------------------------------------------------------------------------------

View File

@ -45,6 +45,7 @@ class QProgressBar;
namespace caf namespace caf
{ {
class TitledOverlayFrame; class TitledOverlayFrame;
class PdmUiSelectionVisualizer3d;
} }
namespace cvf namespace cvf
@ -171,6 +172,8 @@ private:
cvf::ref<RivWindowEdgeAxesOverlayItem> m_windowEdgeAxisOverlay; cvf::ref<RivWindowEdgeAxesOverlayItem> m_windowEdgeAxisOverlay;
bool m_showWindowEdgeAxes; bool m_showWindowEdgeAxes;
caf::PdmUiSelectionVisualizer3d* m_selectionVisualizerManager;
cvf::Vec3d m_cursorPositionDomainCoords; cvf::Vec3d m_cursorPositionDomainCoords;
bool m_isNavigationRotationEnabled; bool m_isNavigationRotationEnabled;
}; };