mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-09 23:16:00 -06:00
#4129 Don't recreate all curves when toggling curve set
This commit is contained in:
parent
0aa7dc1777
commit
26f4577803
@ -130,10 +130,14 @@ void RimGridCrossPlot::calculateZoomRangeAndUpdateQwt()
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimGridCrossPlot::reattachCurvesToQwtAndReplot()
|
||||
{
|
||||
{
|
||||
for (auto curveSet : m_crossPlotCurveSets)
|
||||
{
|
||||
curveSet->setParentQwtPlotNoReplot(m_qwtPlot);
|
||||
curveSet->detachAllCurves();
|
||||
if (curveSet->isChecked())
|
||||
{
|
||||
curveSet->setParentQwtPlotNoReplot(m_qwtPlot);
|
||||
}
|
||||
}
|
||||
m_qwtPlot->replot();
|
||||
}
|
||||
|
@ -335,12 +335,12 @@ void RimGridCrossPlotCurveSet::fieldChangedByUi(const caf::PdmFieldHandle* chang
|
||||
m_yAxisProperty->setEclipseCase(eclipseCase);
|
||||
m_xAxisProperty->updateConnectedEditors();
|
||||
m_yAxisProperty->updateConnectedEditors();
|
||||
triggerReplotAndTreeRebuild();
|
||||
loadDataAndUpdate(true);
|
||||
}
|
||||
}
|
||||
else if (changedField == &m_timeStep)
|
||||
{
|
||||
triggerReplotAndTreeRebuild();
|
||||
loadDataAndUpdate(true);
|
||||
}
|
||||
else if (changedField == &m_isChecked)
|
||||
{
|
||||
@ -388,7 +388,7 @@ void RimGridCrossPlotCurveSet::triggerReplotAndTreeRebuild()
|
||||
{
|
||||
RimGridCrossPlot* parent;
|
||||
this->firstAncestorOrThisOfTypeAsserted(parent);
|
||||
parent->loadDataAndUpdate();
|
||||
parent->reattachCurvesToQwtAndReplot();
|
||||
parent->updateAllRequiredEditors();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user