mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Merge pull request #4720 from OPM/minor-summary-adjustments
Minor summary adjustments
This commit is contained in:
commit
b6dcb6285e
@ -146,7 +146,11 @@ QWidget* RicSummaryCurveCreatorSplitterUi::createWidget( QWidget* parent )
|
||||
|
||||
m_firstColumnSplitter->insertWidget( 0, firstRowFrame );
|
||||
m_firstColumnSplitter->insertWidget( 1, secondRowFrame );
|
||||
m_firstColumnSplitter->setSizes( QList<int>() << 1 << 2 );
|
||||
|
||||
const int firstRowPixelHeight = 500;
|
||||
const int secondRowPixelHeight = 300;
|
||||
|
||||
m_firstColumnSplitter->setSizes( QList<int>() << firstRowPixelHeight << secondRowPixelHeight );
|
||||
|
||||
m_layout->addWidget( m_firstColumnSplitter );
|
||||
|
||||
|
@ -579,7 +579,7 @@ void RiuSummaryCurveDefSelection::setDefaultSelection( const std::vector<Summary
|
||||
|
||||
if ( allSumCases.size() > 0 )
|
||||
{
|
||||
RifEclipseSummaryAddress defaultAddress = RifEclipseSummaryAddress::fieldAddress( "FOPT" );
|
||||
RifEclipseSummaryAddress defaultAddress;
|
||||
|
||||
std::vector<SummarySource*> selectTheseSources = defaultSources;
|
||||
if ( selectTheseSources.empty() ) selectTheseSources.push_back( allSumCases[0] );
|
||||
@ -612,11 +612,6 @@ void RiuSummaryCurveDefSelection::setSelectedCurveDefinitions( const std::vector
|
||||
RimSummaryCase* summaryCase = curveDef.summaryCase();
|
||||
|
||||
RifEclipseSummaryAddress summaryAddress = curveDef.summaryAddress();
|
||||
if ( summaryAddress.category() == RifEclipseSummaryAddress::SUMMARY_INVALID )
|
||||
{
|
||||
// If we have an invalid address, set the default address to Field
|
||||
summaryAddress = RifEclipseSummaryAddress::fieldAddress( summaryAddress.quantityName() );
|
||||
}
|
||||
|
||||
// Ignore ensemble statistics curves
|
||||
if ( summaryAddress.category() == RifEclipseSummaryAddress::SUMMARY_ENSEMBLE_STATISTICS ) continue;
|
||||
@ -627,7 +622,15 @@ void RiuSummaryCurveDefSelection::setSelectedCurveDefinitions( const std::vector
|
||||
if ( std::find( selectedCategories.begin(), selectedCategories.end(), summaryAddress.category() ) ==
|
||||
selectedCategories.end() )
|
||||
{
|
||||
m_selectedSummaryCategories.v().push_back( summaryAddress.category() );
|
||||
if ( summaryAddress.category() != RifEclipseSummaryAddress::SUMMARY_INVALID )
|
||||
{
|
||||
m_selectedSummaryCategories.v().push_back( summaryAddress.category() );
|
||||
}
|
||||
else
|
||||
{
|
||||
// Use field category as fall back category to avoid an empty list of vectors
|
||||
summaryAddress = RifEclipseSummaryAddress::fieldAddress( "" );
|
||||
}
|
||||
}
|
||||
|
||||
// Select case if not already selected
|
||||
|
Loading…
Reference in New Issue
Block a user