Simplify RiuPlotMainWindowTools (#9211)

* Janitor: Add and use onObjectAppended()
* Janitor: Simplify API
This commit is contained in:
Magne Sjaastad
2022-08-18 03:37:51 -07:00
committed by GitHub
parent febbdcf7a0
commit a1e7b64d92
34 changed files with 66 additions and 93 deletions

View File

@@ -81,10 +81,7 @@ void RicAddStoredFlowCharacteristicsPlotFeature::onActionTriggered( bool isCheck
flowPlotColl->updateConnectedEditors();
RiuPlotMainWindowTools::showPlotMainWindow();
RiuPlotMainWindowTools::selectAsCurrentItem( flowCharacteristicsPlot );
RiuPlotMainWindowTools::setExpanded( flowCharacteristicsPlot );
RiuPlotMainWindowTools::refreshToolbars();
RiuPlotMainWindowTools::onObjectAppended( flowCharacteristicsPlot );
}
}
}

View File

@@ -81,9 +81,7 @@ void RicAddStoredWellAllocationPlotFeature::onActionTriggered( bool isChecked )
flowPlotColl->updateConnectedEditors();
RiuPlotMainWindowTools::selectAsCurrentItem( wellAllocationPlot );
RiuPlotMainWindowTools::setExpanded( wellAllocationPlot );
RiuPlotMainWindowTools::refreshToolbars();
RiuPlotMainWindowTools::onObjectAppended( wellAllocationPlot );
}
}
}

View File

@@ -96,9 +96,7 @@ void RicShowFlowCharacteristicsPlotFeature::onActionTriggered( bool isChecked )
flowPlotColl->defaultFlowCharacteristicsPlot()->setFromFlowSolution( eclCase->defaultFlowDiagSolution() );
flowPlotColl->defaultFlowCharacteristicsPlot()->updateConnectedEditors();
// Make sure the summary plot window is created and visible
RiuPlotMainWindowTools::selectAsCurrentItem( flowPlotColl->defaultFlowCharacteristicsPlot() );
RiuPlotMainWindowTools::refreshToolbars();
RiuPlotMainWindowTools::onObjectAppended( flowPlotColl->defaultFlowCharacteristicsPlot() );
}
}
}

View File

@@ -111,10 +111,8 @@ void RicShowWellAllocationPlotFeature::onActionTriggered( bool isChecked )
flowPlotColl->defaultWellAllocPlot()->setFromSimulationWell( simWell );
flowPlotColl->defaultWellAllocPlot()->updateConnectedEditors();
// Make sure the summary plot window is created and visible
RiuPlotMainWindowTools::showPlotMainWindow();
RiuPlotMainWindowTools::selectAsCurrentItem( flowPlotColl->defaultWellAllocPlot() );
RiuPlotMainWindowTools::refreshToolbars();
RiuPlotMainWindowTools::onObjectAppended( flowPlotColl->defaultWellAllocPlot() );
}
}
}