#8359 Plot Project Tree : Always show multi plot collection

If no multi plots was present, the top level collection was not visible. This caused the project tree to collapse when a new plot was created.
This commit is contained in:
Magne Sjaastad 2021-12-09 14:11:48 +01:00
parent 48843c50f6
commit 3938e9e600
2 changed files with 2 additions and 4 deletions

View File

@ -241,10 +241,9 @@ RimMultiPlot* RicSummaryPlotBuilder::createAndAppendMultiPlot( const std::vector
plot->loadDataAndUpdate(); plot->loadDataAndUpdate();
} }
project->updateAllRequiredEditors(); plotCollection->updateAllRequiredEditors();
plotWindow->loadDataAndUpdate(); plotWindow->loadDataAndUpdate();
RiuPlotMainWindowTools::setExpanded( plotCollection, true );
RiuPlotMainWindowTools::selectAsCurrentItem( plotWindow, true ); RiuPlotMainWindowTools::selectAsCurrentItem( plotWindow, true );
return plotWindow; return plotWindow;

View File

@ -1474,8 +1474,7 @@ void RimProject::defineUiTreeOrdering( caf::PdmUiTreeOrdering& uiTreeOrdering, Q
itemCollection->add( mainPlotCollection->saturationPressurePlotCollection() ); itemCollection->add( mainPlotCollection->saturationPressurePlotCollection() );
} }
if ( mainPlotCollection->multiPlotCollection() && if ( mainPlotCollection->multiPlotCollection() )
!mainPlotCollection->multiPlotCollection()->multiPlots().empty() )
{ {
itemCollection->add( mainPlotCollection->multiPlotCollection() ); itemCollection->add( mainPlotCollection->multiPlotCollection() );
} }