mirror of
https://github.com/OPM/ResInsight.git
synced 2025-01-24 15:26:48 -06:00
(#452) Fixed switching of MDI windows
This commit is contained in:
parent
ae42845f35
commit
cc62e93d45
@ -2259,7 +2259,18 @@ std::vector<int> RiuMainWindow::windowGeometryForWidget(QWidget* widget)
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RiuMainWindow::tileWindows()
|
||||
{
|
||||
// Based on workaround described here
|
||||
// https://forum.qt.io/topic/50053/qmdiarea-tilesubwindows-always-places-widgets-in-activationhistoryorder-in-subwindowview-mode
|
||||
|
||||
QMdiSubWindow *a = m_mdiArea->activeSubWindow();
|
||||
QList<QMdiSubWindow *> list = m_mdiArea->subWindowList(m_mdiArea->activationOrder());
|
||||
for (int i = 0; i < list.count(); i++)
|
||||
{
|
||||
m_mdiArea->setActiveSubWindow(list[i]);
|
||||
}
|
||||
|
||||
m_mdiArea->tileSubWindows();
|
||||
m_mdiArea->setActiveSubWindow(a);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
Loading…
Reference in New Issue
Block a user