#992 Fixed invalid access of nullpointer for property filtered geometry

This commit is contained in:
Magne Sjaastad
2016-11-18 10:48:51 +01:00
parent 3ba7ade88e
commit c52e1809ab
3 changed files with 10 additions and 13 deletions

View File

@@ -767,7 +767,16 @@ void RimEclipseView::updateStaticCellColors(RivCellSetEnum geometryType)
case RANGE_FILTERED_INACTIVE: color = cvf::Color4f(cvf::Color3::LIGHT_GRAY); break;
}
m_reservoirGridPartManager->updateCellColor(geometryType, color);
if (geometryType == PROPERTY_FILTERED || geometryType == PROPERTY_FILTERED_WELL_CELLS)
{
// Always use current time step when updating color of property geometry
m_reservoirGridPartManager->updateCellColor(geometryType, m_currentTimeStep, color);
}
else
{
// Use static timestep (timestep 0) for geometry with no change between time steps
m_reservoirGridPartManager->updateCellColor(geometryType, 0, color);
}
}
//--------------------------------------------------------------------------------------------------