mirror of
https://github.com/OPM/ResInsight.git
synced 2024-12-28 18:01:08 -06:00
Refactor: rename confusing push_back method on view collections.
This commit is contained in:
parent
ade044adbf
commit
174123f8b5
@ -98,7 +98,7 @@ void RicPasteEclipseViewsFeature::onActionTriggered( bool isChecked )
|
||||
auto contourMapView = dynamic_cast<RimEclipseContourMapView*>( rimReservoirView );
|
||||
CVF_ASSERT( contourMapView );
|
||||
|
||||
eclipseCase->contourMapCollection()->push_back( contourMapView );
|
||||
eclipseCase->contourMapCollection()->addView( contourMapView );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -219,7 +219,7 @@ RimEclipseContourMapView*
|
||||
|
||||
size_t i = eclipseCase->contourMapCollection()->views().size();
|
||||
contourMap->setName( QString( "Contour Map %1" ).arg( i + 1 ) );
|
||||
eclipseCase->contourMapCollection()->push_back( contourMap );
|
||||
eclipseCase->contourMapCollection()->addView( contourMap );
|
||||
|
||||
// Resolve references after contour map has been inserted into Rim structures
|
||||
contourMap->resolveReferencesRecursively();
|
||||
@ -269,7 +269,7 @@ RimEclipseContourMapView* RicNewContourMapViewFeature::createEclipseContourMapFr
|
||||
|
||||
caf::PdmDocument::updateUiIconStateRecursively( contourMap );
|
||||
|
||||
eclipseCase->contourMapCollection()->push_back( contourMap );
|
||||
eclipseCase->contourMapCollection()->addView( contourMap );
|
||||
|
||||
contourMap->synchronizeLocalAnnotationsFromGlobal();
|
||||
|
||||
@ -313,7 +313,7 @@ RimEclipseContourMapView* RicNewContourMapViewFeature::createEclipseContourMap(
|
||||
contourMap->faultCollection()->setActive( false );
|
||||
contourMap->wellCollection()->isActive = false;
|
||||
|
||||
eclipseCase->contourMapCollection()->push_back( contourMap );
|
||||
eclipseCase->contourMapCollection()->addView( contourMap );
|
||||
|
||||
auto col = RiuGuiTheme::getColorByVariableName( "backgroundColor2" );
|
||||
contourMap->setBackgroundColor( RiaColorTools::fromQColorTo3f( col ) ); // Ignore original view background
|
||||
@ -343,7 +343,7 @@ RimGeoMechContourMapView*
|
||||
|
||||
size_t i = geoMechCase->contourMapCollection()->views().size();
|
||||
contourMap->setName( QString( "Contour Map %1" ).arg( i + 1 ) );
|
||||
geoMechCase->contourMapCollection()->push_back( contourMap );
|
||||
geoMechCase->contourMapCollection()->addView( contourMap );
|
||||
|
||||
// Resolve references after contour map has been inserted into Rim structures
|
||||
contourMap->resolveReferencesRecursively();
|
||||
@ -373,7 +373,7 @@ RimGeoMechContourMapView* RicNewContourMapViewFeature::createGeoMechContourMapFr
|
||||
|
||||
caf::PdmDocument::updateUiIconStateRecursively( contourMap );
|
||||
|
||||
geoMechCase->contourMapCollection()->push_back( contourMap );
|
||||
geoMechCase->contourMapCollection()->addView( contourMap );
|
||||
|
||||
// Resolve references after contour map has been inserted into Rim structures
|
||||
std::vector<caf::PdmFieldHandle*> fieldsWithFailingResolve;
|
||||
@ -395,7 +395,7 @@ RimGeoMechContourMapView* RicNewContourMapViewFeature::createGeoMechContourMap(
|
||||
|
||||
size_t i = geoMechCase->contourMapCollection()->views().size();
|
||||
contourMap->setName( QString( "Contour Map %1" ).arg( i + 1 ) );
|
||||
geoMechCase->contourMapCollection()->push_back( contourMap );
|
||||
geoMechCase->contourMapCollection()->addView( contourMap );
|
||||
|
||||
auto col = RiuGuiTheme::getColorByVariableName( "backgroundColor2" );
|
||||
contourMap->setBackgroundColor( RiaColorTools::fromQColorTo3f( col ) ); // Ignore original view background
|
||||
|
@ -33,7 +33,7 @@ std::vector<RimGeoMechContourMapView*> RimGeoMechContourMapViewCollection::views
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimGeoMechContourMapViewCollection::push_back( RimGeoMechContourMapView* contourMap )
|
||||
void RimGeoMechContourMapViewCollection::addView( RimGeoMechContourMapView* contourMap )
|
||||
{
|
||||
m_contourMapViews.push_back( contourMap );
|
||||
}
|
||||
|
@ -33,7 +33,7 @@ public:
|
||||
~RimGeoMechContourMapViewCollection() override;
|
||||
|
||||
std::vector<RimGeoMechContourMapView*> views();
|
||||
void push_back( RimGeoMechContourMapView* contourMap );
|
||||
void addView( RimGeoMechContourMapView* contourMap );
|
||||
|
||||
private:
|
||||
caf::PdmChildArrayField<RimGeoMechContourMapView*> m_contourMapViews;
|
||||
|
@ -299,7 +299,7 @@ void RimEclipseCase::initAfterRead()
|
||||
{
|
||||
contourMap->setEclipseCase( this );
|
||||
m_contourMapCollection_OBSOLETE->removeChild( contourMap );
|
||||
mapViewColl->push_back( contourMap );
|
||||
mapViewColl->addView( contourMap );
|
||||
}
|
||||
|
||||
m_contourMapCollection_OBSOLETE->clearWithoutDelete();
|
||||
|
@ -33,7 +33,7 @@ std::vector<RimEclipseContourMapView*> RimEclipseContourMapViewCollection::views
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimEclipseContourMapViewCollection::push_back( RimEclipseContourMapView* contourMap )
|
||||
void RimEclipseContourMapViewCollection::addView( RimEclipseContourMapView* contourMap )
|
||||
{
|
||||
m_contourMapViews.push_back( contourMap );
|
||||
}
|
||||
|
@ -33,7 +33,7 @@ public:
|
||||
~RimEclipseContourMapViewCollection() override;
|
||||
|
||||
std::vector<RimEclipseContourMapView*> views();
|
||||
void push_back( RimEclipseContourMapView* contourMap );
|
||||
void addView( RimEclipseContourMapView* contourMap );
|
||||
|
||||
void onChildDeleted( caf::PdmChildArrayFieldHandle* childArray, std::vector<caf::PdmObjectHandle*>& referringObjects ) override;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user