From a0c2d7f6b7da73e2d3c5c77da7a175b495d4be9b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A5l=20Hagen?= Date: Fri, 25 Sep 2015 16:45:38 +0200 Subject: [PATCH] (#525) Checking for availability of any case, not necessarily the active case --- .../RicNewWellLogCurveExtractionFeature.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ApplicationCode/Commands/WellLogCommands/RicNewWellLogCurveExtractionFeature.cpp b/ApplicationCode/Commands/WellLogCommands/RicNewWellLogCurveExtractionFeature.cpp index d09246449e..9a5382f64c 100644 --- a/ApplicationCode/Commands/WellLogCommands/RicNewWellLogCurveExtractionFeature.cpp +++ b/ApplicationCode/Commands/WellLogCommands/RicNewWellLogCurveExtractionFeature.cpp @@ -27,6 +27,7 @@ #include "RimWellPath.h" #include "RimWellPathCollection.h" #include "RimView.h" +#include "RimProject.h" #include "RiuMainWindow.h" #include "RiaApplication.h" @@ -105,8 +106,10 @@ RimWellPath* RicNewWellLogCurveExtractionFeature::selectedWellPath() const //-------------------------------------------------------------------------------------------------- bool RicNewWellLogCurveExtractionFeature::caseAvailable() const { - RimView* view = RiaApplication::instance()->activeReservoirView(); - return view ? view->ownerCase() != NULL : false; + std::vector cases; + RiaApplication::instance()->project()->allCases(cases); + + return cases.size() > 0; } //--------------------------------------------------------------------------------------------------