From 0415f25d0a1cc1c755c097c9356481f41f9bb020 Mon Sep 17 00:00:00 2001 From: Kristian Bendiksen Date: Thu, 3 Sep 2020 16:35:03 +0200 Subject: [PATCH] #6422 Detailed Fluid Loss: hide curves when disabled. --- .../ProjectDataModel/RimFractureModelPlot.cpp | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/ApplicationCode/ProjectDataModel/RimFractureModelPlot.cpp b/ApplicationCode/ProjectDataModel/RimFractureModelPlot.cpp index 9b73144a7e..92cc5013ed 100644 --- a/ApplicationCode/ProjectDataModel/RimFractureModelPlot.cpp +++ b/ApplicationCode/ProjectDataModel/RimFractureModelPlot.cpp @@ -28,6 +28,7 @@ #include "RimFractureModelCurve.h" #include "RimFractureModelPropertyCurve.h" #include "RimLayerCurve.h" +#include "RimWellLogTrack.h" #include "RigWellLogCurveData.h" @@ -90,6 +91,31 @@ void RimFractureModelPlot::defineUiOrdering( QString uiConfigName, caf::PdmUiOrd //-------------------------------------------------------------------------------------------------- void RimFractureModelPlot::onLoadDataAndUpdate() { + // Enable and disable detailed fluid loss curves + if ( fractureModel() != nullptr ) + { + std::vector fluidLossCurves = {RiaDefines::CurveProperty::PORO_ELASTIC_CONSTANT, + RiaDefines::CurveProperty::RELATIVE_PERMEABILITY_FACTOR, + RiaDefines::CurveProperty::THERMAL_EXPANSION_COEFFICIENT, + RiaDefines::CurveProperty::IMMOBILE_FLUID_SATURATION}; + + bool detailedFluidLoss = fractureModel()->useDetailedFluidLoss(); + + for ( auto curveProperty : fluidLossCurves ) + { + RimWellLogExtractionCurve* curve = findCurveByProperty( curveProperty ); + if ( curve ) + { + RimWellLogTrack* track = nullptr; + curve->firstAncestorOfType( track ); + if ( track ) + { + track->setShowWindow( detailedFluidLoss ); + } + } + } + } + RimDepthTrackPlot::onLoadDataAndUpdate(); }