mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#5171 Fix legend updates by getting rid of the show/hideEvent crash fix
* The crash is instead fixed by getting rid of deleteLater()
This commit is contained in:
@@ -160,7 +160,8 @@ void RiuGridCrossQwtPlot::removeDataSetLegend( RimGridCrossPlotDataSet* dataSetT
|
||||
if ( it->second != nullptr )
|
||||
{
|
||||
it->second->hide();
|
||||
it->second->deleteLater();
|
||||
it->second->setParent( nullptr );
|
||||
delete it->second;
|
||||
}
|
||||
|
||||
m_legendWidgets.erase( it );
|
||||
@@ -181,7 +182,8 @@ void RiuGridCrossQwtPlot::removeDanglingDataSetLegends()
|
||||
if ( it->second != nullptr )
|
||||
{
|
||||
it->second->hide();
|
||||
it->second->deleteLater();
|
||||
it->second->setParent( nullptr );
|
||||
delete it->second;
|
||||
}
|
||||
m_legendWidgets.erase( it++ );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user