mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Fix source list in Summary Editor for ensemble plots
This commit is contained in:
@@ -30,7 +30,7 @@
|
||||
RiaSummaryCurveDefinition::RiaSummaryCurveDefinition()
|
||||
: m_summaryCase( nullptr )
|
||||
, m_ensemble( nullptr )
|
||||
|
||||
, m_isEnsembleCurve( false )
|
||||
{
|
||||
}
|
||||
|
||||
@@ -38,22 +38,31 @@ RiaSummaryCurveDefinition::RiaSummaryCurveDefinition()
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RiaSummaryCurveDefinition::RiaSummaryCurveDefinition( RimSummaryCase* summaryCase,
|
||||
const RifEclipseSummaryAddress& summaryAddress )
|
||||
const RifEclipseSummaryAddress& summaryAddress,
|
||||
bool isEnsembleCurve )
|
||||
: m_summaryCase( summaryCase )
|
||||
, m_ensemble( nullptr )
|
||||
, m_summaryAddress( summaryAddress )
|
||||
, m_treatAsSingleSummaryCurve( true )
|
||||
, m_isEnsembleCurve( isEnsembleCurve )
|
||||
{
|
||||
CAF_ASSERT( summaryCase );
|
||||
|
||||
if ( summaryCase )
|
||||
{
|
||||
RimSummaryCaseCollection* ensemble = nullptr;
|
||||
summaryCase->firstAncestorOfType( ensemble );
|
||||
m_ensemble = ensemble;
|
||||
}
|
||||
}
|
||||
|
||||
RiaSummaryCurveDefinition::RiaSummaryCurveDefinition( RimSummaryCase* summaryCase,
|
||||
const RifEclipseSummaryAddress& summaryAddress,
|
||||
RimSummaryCaseCollection* ensemble,
|
||||
bool treatAsSingleSummaryCurve )
|
||||
: m_summaryCase( summaryCase )
|
||||
, m_ensemble( ensemble )
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RiaSummaryCurveDefinition::RiaSummaryCurveDefinition( RimSummaryCaseCollection* ensemble,
|
||||
const RifEclipseSummaryAddress& summaryAddress )
|
||||
: m_summaryCase( nullptr )
|
||||
, m_summaryAddress( summaryAddress )
|
||||
, m_treatAsSingleSummaryCurve( treatAsSingleSummaryCurve )
|
||||
, m_ensemble( ensemble )
|
||||
, m_isEnsembleCurve( true )
|
||||
{
|
||||
}
|
||||
|
||||
@@ -86,7 +95,7 @@ const RifEclipseSummaryAddress& RiaSummaryCurveDefinition::summaryAddress() cons
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaSummaryCurveDefinition::isEnsembleCurve() const
|
||||
{
|
||||
return m_ensemble != nullptr && !m_treatAsSingleSummaryCurve;
|
||||
return m_isEnsembleCurve;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -205,7 +214,12 @@ bool RiaSummaryCurveDefinition::operator<( const RiaSummaryCurveDefinition& othe
|
||||
return m_summaryCase < other.summaryCase();
|
||||
}
|
||||
|
||||
return ( m_summaryAddress < other.summaryAddress() );
|
||||
if ( m_summaryAddress != other.summaryAddress() )
|
||||
{
|
||||
return ( m_summaryAddress < other.summaryAddress() );
|
||||
}
|
||||
|
||||
return m_isEnsembleCurve < other.isEnsembleCurve();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -35,11 +35,10 @@ class RiaSummaryCurveDefinition
|
||||
{
|
||||
public:
|
||||
RiaSummaryCurveDefinition();
|
||||
explicit RiaSummaryCurveDefinition( RimSummaryCase* summaryCase, const RifEclipseSummaryAddress& summaryAddress );
|
||||
explicit RiaSummaryCurveDefinition( RimSummaryCase* summaryCase,
|
||||
const RifEclipseSummaryAddress& summaryAddress,
|
||||
RimSummaryCaseCollection* ensemble,
|
||||
bool treatAsSingleSummaryCurve );
|
||||
bool isEnsembleCurve );
|
||||
explicit RiaSummaryCurveDefinition( RimSummaryCaseCollection* ensemble, const RifEclipseSummaryAddress& summaryAddress );
|
||||
|
||||
RimSummaryCase* summaryCase() const;
|
||||
const RifEclipseSummaryAddress& summaryAddress() const;
|
||||
@@ -60,7 +59,7 @@ private:
|
||||
RimSummaryCase* m_summaryCase;
|
||||
RifEclipseSummaryAddress m_summaryAddress;
|
||||
RimSummaryCaseCollection* m_ensemble;
|
||||
bool m_treatAsSingleSummaryCurve;
|
||||
bool m_isEnsembleCurve;
|
||||
};
|
||||
|
||||
class RiaSummaryCurveDefinitionAnalyser
|
||||
|
||||
Reference in New Issue
Block a user