Fix updates after legend change

This commit is contained in:
Gaute Lindkvist
2019-12-05 12:54:32 +01:00
parent 08afc1f8d7
commit 0b5188e4b7
3 changed files with 12 additions and 2 deletions

View File

@@ -868,7 +868,7 @@ void RimWellRftPlot::fieldChangedByUi( const caf::PdmFieldHandle* changedField,
{
plotTrack->deleteAllCurves();
}
createEnsembleCurveSets();
updateEditorsFromPreviousSelection();
updateFormationsOnPlot();
syncCurvesFromUiSelection();
@@ -878,6 +878,7 @@ void RimWellRftPlot::fieldChangedByUi( const caf::PdmFieldHandle* changedField,
const QString simWellName = associatedSimWellName();
m_branchIndex = RiaSimWellBranchTools::clampBranchIndex( simWellName, m_branchIndex, m_branchDetection );
createEnsembleCurveSets();
updateFormationsOnPlot();
syncCurvesFromUiSelection();
}
@@ -1104,6 +1105,14 @@ bool RimWellRftPlot::showErrorBarsForObservedData() const
return m_showErrorInObservedData();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RimWellRftPlot::onLegendDefinitionChanged()
{
syncCurvesFromUiSelection();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@@ -90,6 +90,7 @@ public:
void deleteCurvesAssosicatedWithObservedData( const RimObservedFmuRftData* observedFmuRftData );
bool showErrorBarsForObservedData() const;
void onLegendDefinitionChanged();
protected:
void fieldChangedByUi( const caf::PdmFieldHandle* changedField,

View File

@@ -303,7 +303,7 @@ void RimRegularLegendConfig::fieldChangedByUi( const caf::PdmFieldHandle* change
firstAncestorOrThisOfType( rftPlot );
if ( rftPlot )
{
rftPlot->loadDataAndUpdate();
rftPlot->onLegendDefinitionChanged();
}
}