mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Change API for PdmObjectHandle and PdmFieldHandle
* Refactor interface to PdmObjectHandle and PdmFieldHandle Return objects instead of passing in structures as parameters * Add nodiscard to several functions * Remove redundant this-> * Rename to ptrReferencedObjectsByType
This commit is contained in:
@@ -170,8 +170,7 @@ void RimEclipseContourMapProjection::clearGridMappingAndRedraw()
|
||||
this->generateResultsIfNecessary( view()->currentTimeStep() );
|
||||
this->updateLegend();
|
||||
|
||||
RimEclipseView* parentView = nullptr;
|
||||
this->firstAncestorOrThisOfTypeAsserted( parentView );
|
||||
RimEclipseView* parentView = firstAncestorOrThisOfTypeAsserted<RimEclipseView>();
|
||||
parentView->scheduleCreateDisplayModelAndRedraw();
|
||||
}
|
||||
|
||||
@@ -387,9 +386,7 @@ std::vector<double> RimEclipseContourMapProjection::retrieveParameterWeights()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimEclipseCase* RimEclipseContourMapProjection::eclipseCase() const
|
||||
{
|
||||
RimEclipseCase* eclipseCase = nullptr;
|
||||
firstAncestorOrThisOfType( eclipseCase );
|
||||
return eclipseCase;
|
||||
return firstAncestorOrThisOfType<RimEclipseCase>();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -509,9 +506,7 @@ size_t RimEclipseContourMapProjection::gridResultIndex( size_t globalCellIdx ) c
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimEclipseContourMapView* RimEclipseContourMapProjection::view() const
|
||||
{
|
||||
RimEclipseContourMapView* view = nullptr;
|
||||
firstAncestorOrThisOfTypeAsserted( view );
|
||||
return view;
|
||||
return firstAncestorOrThisOfTypeAsserted<RimEclipseContourMapView>();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user