mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Fix crash during delete of multiplot
This commit is contained in:
@@ -45,6 +45,7 @@ CAF_PDM_SOURCE_INIT( RimMultiPlot, "MultiPlot" );
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimMultiPlot::RimMultiPlot()
|
||||
: m_isValid( true )
|
||||
{
|
||||
CAF_PDM_InitObject( "Multi Plot", ":/MultiPlot16x16.png" );
|
||||
|
||||
@@ -84,6 +85,8 @@ RimMultiPlot::RimMultiPlot()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimMultiPlot::~RimMultiPlot()
|
||||
{
|
||||
m_isValid = false;
|
||||
|
||||
removeMdiWindowFromMdiArea();
|
||||
m_plots.deleteAllChildObjects();
|
||||
|
||||
@@ -897,3 +900,11 @@ std::vector<caf::PdmFieldHandle*> RimMultiPlot::fieldsToShowInToolbar()
|
||||
{
|
||||
return { &m_pagePreviewMode, &m_columnCount, &m_rowsPerPage };
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RimMultiPlot::isValid() const
|
||||
{
|
||||
return m_isValid;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user