mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Update GUI editor if a new summary vector is set created
Make sure the user interface is updated when summary data is set from Python using summary_case.set_summary_values
This commit is contained in:
parent
c1b44e0d51
commit
78759feb15
@ -18,7 +18,6 @@
|
||||
|
||||
#include "RimcSummaryCase.h"
|
||||
|
||||
#include "RiaQDateTimeTools.h"
|
||||
#include "RiaSummaryTools.h"
|
||||
|
||||
#include "RifSummaryReaderInterface.h"
|
||||
@ -276,7 +275,27 @@ caf::PdmObjectHandle* RimSummaryCase_setSummaryVectorValues::execute()
|
||||
auto* fileSummaryCase = dynamic_cast<RimFileSummaryCase*>( summaryCase );
|
||||
if ( fileSummaryCase )
|
||||
{
|
||||
bool rebuildUserInterface = true;
|
||||
|
||||
if ( auto reader = fileSummaryCase->summaryReader() )
|
||||
{
|
||||
auto allAddr = reader->allResultAddresses();
|
||||
for ( auto adr : allAddr )
|
||||
{
|
||||
if ( adr.uiText() == m_addressString().toStdString() )
|
||||
{
|
||||
rebuildUserInterface = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fileSummaryCase->setSummaryData( m_addressString().toStdString(), m_unitString().toStdString(), m_values() );
|
||||
|
||||
if ( rebuildUserInterface )
|
||||
{
|
||||
fileSummaryCase->refreshMetaData();
|
||||
}
|
||||
}
|
||||
|
||||
return nullptr;
|
||||
|
Loading…
Reference in New Issue
Block a user