mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#717 Octave script can not be executed for multiple case in Project Tree
This commit is contained in:
parent
97232fedd4
commit
c6a41cc18f
@ -78,14 +78,6 @@ QStringList RimContextCommandBuilder::commandsFromSelection()
|
||||
{
|
||||
commandIds << "RicNewWellLogPlotFeature";
|
||||
}
|
||||
else if (uiItems.size() > 1)
|
||||
{
|
||||
caf::PdmUiItem* uiItem = uiItems[0];
|
||||
if (dynamic_cast<RimWellLogFileChannel*>(uiItem))
|
||||
{
|
||||
commandIds << "RicAddWellLogToPlotFeature";
|
||||
}
|
||||
}
|
||||
else if (uiItems.size() == 1)
|
||||
{
|
||||
caf::PdmUiItem* uiItem = uiItems[0];
|
||||
@ -124,7 +116,6 @@ QStringList RimContextCommandBuilder::commandsFromSelection()
|
||||
commandIds << "RicNewViewFeature";
|
||||
commandIds << "RicComputeStatisticsFeature";
|
||||
commandIds << "RicCloseCaseFeature";
|
||||
commandIds << "RicExecuteScriptForCasesFeature";
|
||||
}
|
||||
else if (dynamic_cast<RimEclipseCase*>(uiItem))
|
||||
{
|
||||
@ -136,7 +127,6 @@ QStringList RimContextCommandBuilder::commandsFromSelection()
|
||||
commandIds << "RicCloseCaseFeature";
|
||||
commandIds << "RicNewViewFeature";
|
||||
commandIds << "RicEclipseCaseNewGroupFeature";
|
||||
commandIds << "RicExecuteScriptForCasesFeature";
|
||||
}
|
||||
else if (dynamic_cast<RimGeoMechCase*>(uiItem))
|
||||
{
|
||||
@ -259,10 +249,6 @@ QStringList RimContextCommandBuilder::commandsFromSelection()
|
||||
commandIds << "RicExportToLasFileFeature";
|
||||
commandIds << "RicDeleteItemFeature";
|
||||
}
|
||||
else if (dynamic_cast<RimWellLogFileChannel*>(uiItem))
|
||||
{
|
||||
commandIds << "RicAddWellLogToPlotFeature";
|
||||
}
|
||||
else if (dynamic_cast<RimCrossSectionCollection*>(uiItem))
|
||||
{
|
||||
commandIds << "RicAppendCrossSectionFeature";
|
||||
@ -287,6 +273,24 @@ QStringList RimContextCommandBuilder::commandsFromSelection()
|
||||
}
|
||||
}
|
||||
|
||||
// Command supporting multiple selected objects
|
||||
if (uiItems.size() > 0)
|
||||
{
|
||||
caf::PdmUiItem* uiItem = uiItems[0];
|
||||
if (dynamic_cast<RimWellLogFileChannel*>(uiItem))
|
||||
{
|
||||
commandIds << "RicAddWellLogToPlotFeature";
|
||||
}
|
||||
else if (dynamic_cast<RimEclipseStatisticsCase*>(uiItem))
|
||||
{
|
||||
commandIds << "RicExecuteScriptForCasesFeature";
|
||||
}
|
||||
else if (dynamic_cast<RimEclipseCase*>(uiItem))
|
||||
{
|
||||
commandIds << "RicExecuteScriptForCasesFeature";
|
||||
}
|
||||
}
|
||||
|
||||
if (RicToggleItemsFeatureImpl::isToggleCommandsAvailable())
|
||||
{
|
||||
commandIds << "Separator";
|
||||
|
Loading…
Reference in New Issue
Block a user