mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#4262 Tidy up well path menus
This commit is contained in:
@@ -84,7 +84,7 @@ RiuWellPathSelectionItem* RicNewFishbonesSubsAtMeasuredDepthFeature::wellPathSel
|
||||
void RicNewFishbonesSubsAtMeasuredDepthFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/FishBoneGroup16x16.png"));
|
||||
actionToSetup->setText("New Fishbones");
|
||||
actionToSetup->setText("Create Fishbones at this Depth");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
#include "RimFishbonesMultipleSubs.h"
|
||||
#include "Rim3dView.h"
|
||||
#include "RimWellPathCollection.h"
|
||||
#include "RimWellPathCompletions.h"
|
||||
|
||||
#include "RiuMainWindow.h"
|
||||
|
||||
@@ -112,6 +113,11 @@ RimFishbonesCollection* RicNewFishbonesSubsFeature::selectedFishbonesCollection(
|
||||
{
|
||||
return wellPaths[0]->fishbonesCollection();
|
||||
}
|
||||
RimWellPathCompletions* completions = caf::SelectionManager::instance()->selectedItemOfType<RimWellPathCompletions>();
|
||||
if (completions)
|
||||
{
|
||||
return completions->fishbonesCollection();
|
||||
}
|
||||
}
|
||||
|
||||
return objToFind;
|
||||
@@ -123,7 +129,7 @@ RimFishbonesCollection* RicNewFishbonesSubsFeature::selectedFishbonesCollection(
|
||||
void RicNewFishbonesSubsFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/FishBoneGroup16x16.png"));
|
||||
actionToSetup->setText("New Fishbones");
|
||||
actionToSetup->setText("Create Fishbones");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -84,7 +84,7 @@ RiuWellPathSelectionItem* RicNewPerforationIntervalAtMeasuredDepthFeature::wellP
|
||||
void RicNewPerforationIntervalAtMeasuredDepthFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/PerforationIntervals16x16.png"));
|
||||
actionToSetup->setText("New Perforation Interval");
|
||||
actionToSetup->setText("Create Perforation Interval at this Depth");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include "RimPerforationInterval.h"
|
||||
#include "RimPerforationCollection.h"
|
||||
#include "RimWellPathCollection.h"
|
||||
#include "RimWellPathCompletions.h"
|
||||
|
||||
#include "cafSelectionManager.h"
|
||||
|
||||
@@ -75,7 +76,7 @@ void RicNewPerforationIntervalFeature::onActionTriggered(bool isChecked)
|
||||
void RicNewPerforationIntervalFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/PerforationInterval16x16.png"));
|
||||
actionToSetup->setText("New Perforation Interval");
|
||||
actionToSetup->setText("Create Perforation Interval");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -101,6 +102,11 @@ RimPerforationCollection* RicNewPerforationIntervalFeature::selectedPerforationC
|
||||
{
|
||||
return wellPaths[0]->perforationIntervalCollection();
|
||||
}
|
||||
RimWellPathCompletions* completions = caf::SelectionManager::instance()->selectedItemOfType<RimWellPathCompletions>();
|
||||
if (completions)
|
||||
{
|
||||
return completions->perforationCollection();
|
||||
}
|
||||
}
|
||||
|
||||
return objToFind;
|
||||
|
||||
@@ -65,5 +65,5 @@ void RicNewValveFeature::onActionTriggered(bool isChecked)
|
||||
void RicNewValveFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/ICDValve16x16.png"));
|
||||
actionToSetup->setText("New Valve");
|
||||
actionToSetup->setText("Create Valve");
|
||||
}
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
#include "RimSimWellInViewCollection.h"
|
||||
#include "RimWellPath.h"
|
||||
#include "RimWellPathCollection.h"
|
||||
#include "RimWellPathCompletions.h"
|
||||
#include "RimWellPathFracture.h"
|
||||
|
||||
#include "Riu3DMainWindowTools.h"
|
||||
@@ -173,7 +174,15 @@ void RicWellPathExportCompletionDataFeature::onActionTriggered(bool isChecked)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RicWellPathExportCompletionDataFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setText("Export Completion Data for Selected Well Paths");
|
||||
std::vector<RimWellPath*> selected = selectedWellPaths();
|
||||
if (selected.size() == 1u)
|
||||
{
|
||||
actionToSetup->setText("Export Completion Data for Current Well Path");
|
||||
}
|
||||
else
|
||||
{
|
||||
actionToSetup->setText("Export Completion Data for Selected Well Paths");
|
||||
}
|
||||
actionToSetup->setIcon(QIcon(":/ExportCompletionsSymbol16x16.png"));
|
||||
|
||||
}
|
||||
@@ -189,5 +198,16 @@ std::vector<RimWellPath*> RicWellPathExportCompletionDataFeature::selectedWellPa
|
||||
std::set<RimWellPath*> uniqueWellPaths(wellPaths.begin(), wellPaths.end());
|
||||
wellPaths.assign(uniqueWellPaths.begin(), uniqueWellPaths.end());
|
||||
|
||||
if (wellPaths.empty())
|
||||
{
|
||||
RimWellPathCompletions* completions = caf::SelectionManager::instance()->selectedItemOfType<RimWellPathCompletions>();
|
||||
if (completions)
|
||||
{
|
||||
RimWellPath* wellPath = nullptr;
|
||||
completions->firstAncestorOrThisOfTypeAsserted(wellPath);
|
||||
wellPaths.push_back(wellPath);
|
||||
}
|
||||
}
|
||||
|
||||
return wellPaths;
|
||||
}
|
||||
|
||||
@@ -75,7 +75,7 @@ void RicNewWellPathIntersectionFeature::onActionTriggered(bool isChecked)
|
||||
void RicNewWellPathIntersectionFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/CrossSection16x16.png"));
|
||||
actionToSetup->setText("New Intersection");
|
||||
actionToSetup->setText("Create Intersection");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -129,7 +129,7 @@ void RicNewSimWellFractureAtPosFeature::onActionTriggered(bool isChecked)
|
||||
void RicNewSimWellFractureAtPosFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/FractureSymbol16x16.png"));
|
||||
actionToSetup->setText("New Fracture");
|
||||
actionToSetup->setText("Create Fracture");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -55,7 +55,7 @@ void RicNewWellPathFractureAtPosFeature::onActionTriggered(bool isChecked)
|
||||
void RicNewWellPathFractureAtPosFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/FractureSymbol16x16.png"));
|
||||
actionToSetup->setText("New Fracture");
|
||||
actionToSetup->setText("Create Fracture at this Depth");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
#include "RimStimPlanColors.h"
|
||||
#include "RimWellPath.h"
|
||||
#include "RimWellPathCollection.h"
|
||||
#include "RimWellPathCompletions.h"
|
||||
#include "RimWellPathFracture.h"
|
||||
#include "RimWellPathFractureCollection.h"
|
||||
|
||||
@@ -127,7 +128,7 @@ void RicNewWellPathFractureFeature::onActionTriggered(bool isChecked)
|
||||
void RicNewWellPathFractureFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/FractureSymbol16x16.png"));
|
||||
actionToSetup->setText("New Fracture");
|
||||
actionToSetup->setText("Create Fracture");
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -166,6 +167,11 @@ RimWellPathFractureCollection* RicNewWellPathFractureFeature::selectedWellPathFr
|
||||
{
|
||||
return wellPaths[0]->fractureCollection();
|
||||
}
|
||||
RimWellPathCompletions* completions = caf::SelectionManager::instance()->selectedItemOfType<RimWellPathCompletions>();
|
||||
if (completions)
|
||||
{
|
||||
return completions->fractureCollection();
|
||||
}
|
||||
}
|
||||
|
||||
return objToFind;
|
||||
|
||||
@@ -84,7 +84,7 @@ void RicCreateGridCrossPlotFeature::setupActionLook(QAction* actionToSetup)
|
||||
caf::SelectionManager::instance()->selectedItemAncestorOfType<RimGridCrossPlotCollection>();
|
||||
if (!collection)
|
||||
{
|
||||
actionToSetup->setText("New Grid Cross Plot from 3d View");
|
||||
actionToSetup->setText("Create Grid Cross Plot from 3d View");
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -81,5 +81,5 @@ void RicAdd3dWellLogCurveFeature::onActionTriggered(bool isChecked)
|
||||
void RicAdd3dWellLogCurveFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/WellLogCurve16x16.png"));
|
||||
actionToSetup->setText("Add 3D Well Log Curve");
|
||||
actionToSetup->setText("Create 3D Well Log Curve");
|
||||
}
|
||||
|
||||
@@ -72,5 +72,5 @@ void RicAdd3dWellLogFileCurveFeature::onActionTriggered(bool isChecked)
|
||||
void RicAdd3dWellLogFileCurveFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/WellLogCurve16x16.png"));
|
||||
actionToSetup->setText("Add 3D Well Log LAS Curve");
|
||||
actionToSetup->setText("Create 3D Well Log LAS Curve");
|
||||
}
|
||||
|
||||
@@ -77,5 +77,5 @@ void RicAdd3dWellLogRftCurveFeature::onActionTriggered(bool isChecked)
|
||||
void RicAdd3dWellLogRftCurveFeature::setupActionLook(QAction* actionToSetup)
|
||||
{
|
||||
actionToSetup->setIcon(QIcon(":/WellLogCurve16x16.png"));
|
||||
actionToSetup->setText("Add 3D Well Log RFT Curve");
|
||||
actionToSetup->setText("Create 3D Well Log RFT Curve");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user