mirror of
https://github.com/OPM/ResInsight.git
synced 2026-10-16 10:22:15 -05:00
Allow opening summary plot editor from context menu when multiple cases are selected in data sources
This commit is contained in:
1 parent
22696beed8
commit
bbb8185a24
1 file changed
+6
@@ -55,6 +55,12 @@ bool RicOpenSummaryPlotEditorFeature::isCommandEnabled()
|
||||
RimSummaryMultiPlot* multiPlot = nullptr;
|
||||
RimCustomObjectiveFunctionCollection* customObjFuncCollection = nullptr;
|
||||
|
||||
std::vector<RimSummaryCase*> selectedCases = caf::selectedObjectsByType<RimSummaryCase*>();
|
||||
if ( selectedCases.size() > 0 ) return true;
|
||||
|
||||
std::vector<RimSummaryCaseCollection*> selectedGroups = caf::selectedObjectsByType<RimSummaryCaseCollection*>();
|
||||
if ( selectedGroups.size() > 0 ) return true;
|
||||
|
||||
caf::PdmObject* selObj = dynamic_cast<caf::PdmObject*>( caf::SelectionManager::instance()->selectedItem() );
|
||||
if ( !selObj ) return false;
|
||||
|
||||
|
||||
Reference in new issue
Block a user