mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#5388 Make sure plots aren't unchecked if the parent is unchecked
This commit is contained in:
parent
e4ffa5d7b9
commit
98dfa8a72b
@ -216,9 +216,17 @@ void RimPlot::onCurveSelected( QwtPlotCurve* curve, bool toggle )
|
|||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
void RimPlot::onViewerDestroyed()
|
void RimPlot::onViewerDestroyed()
|
||||||
{
|
{
|
||||||
|
RimPlotWindow* parent = nullptr;
|
||||||
|
this->firstAncestorOfType( parent );
|
||||||
|
|
||||||
|
bool isIndependentPlot = parent == nullptr;
|
||||||
|
bool hasVisibleParent = parent && parent->showWindow();
|
||||||
|
if ( isIndependentPlot || hasVisibleParent )
|
||||||
|
{
|
||||||
m_showWindow = false;
|
m_showWindow = false;
|
||||||
updateConnectedEditors();
|
updateConnectedEditors();
|
||||||
updateUiIconFromToggleField();
|
updateUiIconFromToggleField();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//--------------------------------------------------------------------------------------------------
|
//--------------------------------------------------------------------------------------------------
|
||||||
|
Loading…
Reference in New Issue
Block a user