From 2d047aab841a2532e726557f5577bafa5f035c59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Jensen?= Date: Tue, 24 Oct 2017 08:18:03 +0200 Subject: [PATCH] WellLogPlot. Automatically select well log file when only one exists --- .../WellLogCommands/RicNewWellLogFileCurveFeature.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/ApplicationCode/Commands/WellLogCommands/RicNewWellLogFileCurveFeature.cpp b/ApplicationCode/Commands/WellLogCommands/RicNewWellLogFileCurveFeature.cpp index dbdbc74538..344fd5632e 100644 --- a/ApplicationCode/Commands/WellLogCommands/RicNewWellLogFileCurveFeature.cpp +++ b/ApplicationCode/Commands/WellLogCommands/RicNewWellLogFileCurveFeature.cpp @@ -72,6 +72,11 @@ void RicNewWellLogFileCurveFeature::onActionTriggered(bool isChecked) RimWellLogTrack* wellLogPlotTrack = RicNewWellLogPlotFeatureImpl::createWellLogPlotTrack(); RimWellLogFileCurve* plotCurve = RicWellLogTools::addFileCurve(wellLogPlotTrack); plotCurve->setWellPath(wellPath); + + if (wellPath->wellLogFiles().size() == 1) + { + plotCurve->setWellLogFile(wellPath->wellLogFiles().front()); + } plotCurve->updateConnectedEditors(); } }