mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Simplify RiuPlotMainWindowTools (#9211)
* Janitor: Add and use onObjectAppended() * Janitor: Simplify API
This commit is contained in:
@@ -81,10 +81,7 @@ void RicAddStoredFlowCharacteristicsPlotFeature::onActionTriggered( bool isCheck
|
||||
flowPlotColl->updateConnectedEditors();
|
||||
|
||||
RiuPlotMainWindowTools::showPlotMainWindow();
|
||||
|
||||
RiuPlotMainWindowTools::selectAsCurrentItem( flowCharacteristicsPlot );
|
||||
RiuPlotMainWindowTools::setExpanded( flowCharacteristicsPlot );
|
||||
RiuPlotMainWindowTools::refreshToolbars();
|
||||
RiuPlotMainWindowTools::onObjectAppended( flowCharacteristicsPlot );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -81,9 +81,7 @@ void RicAddStoredWellAllocationPlotFeature::onActionTriggered( bool isChecked )
|
||||
|
||||
flowPlotColl->updateConnectedEditors();
|
||||
|
||||
RiuPlotMainWindowTools::selectAsCurrentItem( wellAllocationPlot );
|
||||
RiuPlotMainWindowTools::setExpanded( wellAllocationPlot );
|
||||
RiuPlotMainWindowTools::refreshToolbars();
|
||||
RiuPlotMainWindowTools::onObjectAppended( wellAllocationPlot );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -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() );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -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() );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user