mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#2843 Fix missing 2d intersection view name updates
This commit is contained in:
@@ -116,11 +116,8 @@ void Rim2dIntersectionView::setIntersection(RimIntersection* intersection)
|
|||||||
CAF_ASSERT(intersection);
|
CAF_ASSERT(intersection);
|
||||||
|
|
||||||
m_intersection = intersection;
|
m_intersection = intersection;
|
||||||
Rim3dView * parentView = nullptr;
|
|
||||||
intersection->firstAncestorOrThisOfTypeAsserted(parentView);
|
|
||||||
name = parentView->name() + ": " + intersection->name();
|
|
||||||
|
|
||||||
|
|
||||||
|
this->updateName();
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
@@ -296,6 +293,19 @@ void Rim2dIntersectionView::update3dInfo()
|
|||||||
m_viewer->update();
|
m_viewer->update();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
///
|
||||||
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
void Rim2dIntersectionView::updateName()
|
||||||
|
{
|
||||||
|
if ( m_intersection )
|
||||||
|
{
|
||||||
|
Rim3dView * parentView = nullptr;
|
||||||
|
m_intersection->firstAncestorOrThisOfTypeAsserted(parentView);
|
||||||
|
name = parentView->name() + ": " + m_intersection->name();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
///
|
///
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
|||||||
@@ -61,6 +61,7 @@ public:
|
|||||||
virtual bool isTimeStepDependentDataVisible() const override;
|
virtual bool isTimeStepDependentDataVisible() const override;
|
||||||
|
|
||||||
void update3dInfo();
|
void update3dInfo();
|
||||||
|
void updateName();
|
||||||
|
|
||||||
cvf::ref<RivIntersectionPartMgr> flatIntersectionPartMgr() const;
|
cvf::ref<RivIntersectionPartMgr> flatIntersectionPartMgr() const;
|
||||||
cvf::Vec3d transformToUtm(const cvf::Vec3d& unscaledPointInFlatDomain) const;
|
cvf::Vec3d transformToUtm(const cvf::Vec3d& unscaledPointInFlatDomain) const;
|
||||||
|
|||||||
@@ -165,6 +165,16 @@ void RimIntersection::fieldChangedByUi(const caf::PdmFieldHandle* changedField,
|
|||||||
updateName();
|
updateName();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (changedField == &name)
|
||||||
|
{
|
||||||
|
Rim2dIntersectionView* iView = correspondingIntersectionView();
|
||||||
|
if (iView)
|
||||||
|
{
|
||||||
|
iView->updateName();
|
||||||
|
iView->updateConnectedEditors();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (changedField == &inputPolyLineFromViewerEnabled
|
if (changedField == &inputPolyLineFromViewerEnabled
|
||||||
|| changedField == &m_userPolyline)
|
|| changedField == &m_userPolyline)
|
||||||
{
|
{
|
||||||
@@ -612,6 +622,12 @@ void RimIntersection::updateName()
|
|||||||
name = wellPath()->name();
|
name = wellPath()->name();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Rim2dIntersectionView* iView = correspondingIntersectionView();
|
||||||
|
if (iView)
|
||||||
|
{
|
||||||
|
iView->updateName();
|
||||||
|
iView->updateConnectedEditors();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
|||||||
Reference in New Issue
Block a user