mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
#851 Added "Open 3D Window" tool button in plot window. Raise mainWindow when activated from toolbar
This commit is contained in:
@@ -1387,10 +1387,8 @@ RiuMainPlotWindow* RiaApplication::getOrCreateAndShowMainPlotWindow()
|
||||
createMainPlotWindow();
|
||||
}
|
||||
|
||||
if (!m_mainPlotWindow->isVisible())
|
||||
{
|
||||
m_mainPlotWindow->show();
|
||||
}
|
||||
m_mainPlotWindow->show();
|
||||
m_mainPlotWindow->raise();
|
||||
|
||||
return m_mainPlotWindow;
|
||||
}
|
||||
@@ -1440,6 +1438,37 @@ RimViewWindow* RiaApplication::activeViewWindow()
|
||||
return viewWindow;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaApplication::tryCloseMainWindow()
|
||||
{
|
||||
RiuMainWindow* mainWindow = RiuMainWindow::instance();
|
||||
if (mainWindow && !mainWindow->isVisible())
|
||||
{
|
||||
mainWindow->close();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
bool RiaApplication::tryClosePlotWindow()
|
||||
{
|
||||
if (m_mainPlotWindow && !m_mainPlotWindow->isVisible())
|
||||
{
|
||||
m_mainPlotWindow->close();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user