#2378 Fractures: Hide "Fracture Colors" in Project tree when not in use

This commit is contained in:
Rebecca Cox
2018-01-18 15:04:04 +01:00
parent 28ea6f054c
commit 79539c1c99
4 changed files with 51 additions and 2 deletions

View File

@@ -71,6 +71,7 @@
#ifdef USE_PROTOTYPE_FEATURE_FRACTURES
#include "RimFracture.h"
#include "RimFractureTemplateCollection.h"
#include "RimSimWellFracture.h"
#include "RivWellFracturePartMgr.h"
#endif // USE_PROTOTYPE_FEATURE_FRACTURES
@@ -1469,7 +1470,18 @@ void RimEclipseView::defineUiTreeOrdering(caf::PdmUiTreeOrdering& uiTreeOrdering
uiTreeOrdering.add(cellEdgeResult());
uiTreeOrdering.add(faultResultSettings());
#ifdef USE_PROTOTYPE_FEATURE_FRACTURES
uiTreeOrdering.add(stimPlanColors());
RimProject* project = RiaApplication::instance()->project();
CVF_ASSERT(project);
RimOilField* oilfield = project->activeOilField();
if (oilfield && oilfield->fractureDefinitionCollection().notNull())
{
if (!oilfield->fractureDefinitionCollection()->fractureDefinitions.empty())
{
uiTreeOrdering.add(stimPlanColors());
}
}
#endif // USE_PROTOTYPE_FEATURE_FRACTURES
uiTreeOrdering.add(wellCollection());