#1068 Added mainGrid() to RimEclipseView

This commit is contained in:
Magne Sjaastad 2017-01-09 10:37:07 +01:00
parent 46bc8e80aa
commit 45b581dc74
2 changed files with 18 additions and 2 deletions

View File

@ -1157,7 +1157,7 @@ void RimEclipseView::setEclipseCase(RimEclipseCase* reservoir)
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RimEclipseCase* RimEclipseView::eclipseCase()
RimEclipseCase* RimEclipseView::eclipseCase() const
{
return m_reservoir;
}
@ -1529,6 +1529,19 @@ RimCase* RimEclipseView::ownerCase()
return eclipseCase();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RigMainGrid* RimEclipseView::mainGrid() const
{
if (eclipseCase() && eclipseCase()->reservoirData())
{
return eclipseCase()->reservoirData()->mainGrid();
}
return nullptr;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@ -40,6 +40,7 @@ class RigActiveCellInfo;
class RigCaseCellResultsData;
class RigGridBase;
class RigGridCellFaceVisibilityFilter;
class RigMainGrid;
class Rim3dOverlayInfoConfig;
class RimEclipseCase;
class RimCellEdgeColors;
@ -112,9 +113,11 @@ public:
RimEclipseCellColors* currentFaultResultColors();
void setEclipseCase(RimEclipseCase* reservoir);
RimEclipseCase* eclipseCase();
RimEclipseCase* eclipseCase() const;
virtual RimCase* ownerCase();
RigMainGrid* mainGrid() const;
// Display model generation
virtual void loadDataAndUpdate();