Skip to content

Commit

Permalink
#11422 Grid Ensemble: Fix copy and paste of a view.
Browse files Browse the repository at this point in the history
Fixes #11422.
  • Loading branch information
kriben committed Aug 28, 2024
1 parent 0572069 commit 8886905
Showing 1 changed file with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#include "RimEclipseContourMapView.h"
#include "RimEclipseContourMapViewCollection.h"
#include "RimEclipseView.h"
#include "RimEclipseViewCollection.h"
#include "RimSimWellInViewCollection.h"

#include "Riu3DMainWindowTools.h"
Expand Down Expand Up @@ -99,9 +100,13 @@ void RicPasteEclipseViewsFeature::onActionTriggered( bool isChecked )

eclipseCase->contourMapCollection()->addView( contourMapView );
}
else if ( auto viewCollection = dynamic_cast<RimEclipseViewCollection*>( destinationObject ) )
{
viewCollection->addView( rimReservoirView );
}
else
{
eclipseCase->reservoirViews().push_back( rimReservoirView );
eclipseCase->viewCollection()->addView( rimReservoirView );
}

rimReservoirView->setEclipseCase( eclipseCase );
Expand Down

0 comments on commit 8886905

Please sign in to comment.