mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#4410 Dock Window State : Use hideAllDockWidgets() in base class
This commit is contained in:
@@ -271,7 +271,7 @@ void RiuMainWindow::cleanupGuiBeforeProjectClose()
|
||||
void RiuMainWindow::closeEvent(QCloseEvent* event)
|
||||
{
|
||||
this->saveWinGeoAndDockToolBarLayout();
|
||||
this->hideAllDockWindows();
|
||||
this->hideAllDockWidgets();
|
||||
|
||||
RiaGuiApplication* app = RiaGuiApplication::instance();
|
||||
if (app->isMainPlotWindowVisible())
|
||||
@@ -1501,19 +1501,6 @@ void RiuMainWindow::slotSnapshotAllViewsToFile()
|
||||
RicSnapshotAllViewsToFileFeature::exportSnapshotOfAllViewsIntoFolder(absolutePathToSnapshotDir);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuMainWindow::hideAllDockWindows()
|
||||
{
|
||||
QList<QDockWidget*> dockWidgets = findChildren<QDockWidget*>();
|
||||
|
||||
for (auto* dockWidget : dockWidgets)
|
||||
{
|
||||
dockWidget->close();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1675,25 +1662,6 @@ void RiuMainWindow::restoreTreeViewState()
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuMainWindow::showDockPanel(const QString& dockPanelName)
|
||||
{
|
||||
QList<QDockWidget*> dockWidgets = findChildren<QDockWidget*>();
|
||||
|
||||
foreach (QDockWidget* dock, dockWidgets)
|
||||
{
|
||||
if (dock && dock->objectName() == dockPanelName)
|
||||
{
|
||||
dock->show();
|
||||
dock->raise();
|
||||
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -1781,7 +1749,7 @@ void RiuMainWindow::updateMemoryUsage()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuMainWindow::showProcessMonitorDockPanel()
|
||||
{
|
||||
showDockPanel(RiuDockWidgetTools::processMonitorName());
|
||||
RiuDockWidgetTools::trySetDockWidgetVisibility(this, RiuDockWidgetTools::processMonitorName(), true);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user