mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#2298 Fracture. Update fracture colors when changing stim plan legend settings
This commit is contained in:
@@ -179,22 +179,7 @@ void RimStimPlanColors::fieldChangedByUi(const caf::PdmFieldHandle* changedField
|
||||
|
||||
if (changedField == &m_resultNameAndUnit)
|
||||
{
|
||||
//Get all frac templates and re-generate stimplan cells
|
||||
RimProject* proj;
|
||||
this->firstAncestorOrThisOfType(proj);
|
||||
if (proj)
|
||||
{
|
||||
std::vector<RimStimPlanFractureTemplate*> stimPlanFracTemplates;
|
||||
proj->descendantsIncludingThisOfType(stimPlanFracTemplates);
|
||||
for (RimStimPlanFractureTemplate* stimPlanFracTemplate : stimPlanFracTemplates)
|
||||
{
|
||||
stimPlanFracTemplate->updateFractureGrid();
|
||||
}
|
||||
proj->createDisplayModelAndRedrawAllViews();
|
||||
}
|
||||
|
||||
|
||||
|
||||
updateStimPlanTemplates();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -281,6 +266,26 @@ void RimStimPlanColors::updateLegendData()
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimStimPlanColors::updateStimPlanTemplates() const
|
||||
{
|
||||
//Get all frac templates and re-generate stimplan cells
|
||||
RimProject* proj;
|
||||
this->firstAncestorOrThisOfType(proj);
|
||||
if (proj)
|
||||
{
|
||||
std::vector<RimStimPlanFractureTemplate*> stimPlanFracTemplates;
|
||||
proj->descendantsIncludingThisOfType(stimPlanFracTemplates);
|
||||
for (RimStimPlanFractureTemplate* stimPlanFracTemplate : stimPlanFracTemplates)
|
||||
{
|
||||
stimPlanFracTemplate->updateFractureGrid();
|
||||
}
|
||||
proj->createDisplayModelAndRedrawAllViews();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user