Merge pull request #211 from aws-lumberyard-dev/cgalvan/FixEMFXDocking

[LYN-3137] Fixed EMFX floating dock widgets not responding to docking events.
This commit is contained in:
cgalvan
2021-04-21 16:06:26 -05:00
committed by GitHub
2 changed files with 7 additions and 3 deletions
@@ -2298,6 +2298,12 @@ namespace AzQtComponents
OptimizedSetParent(dock, mainWindow);
mainWindow->addDockWidget(Qt::LeftDockWidgetArea, dock);
dock->show();
// Make sure we listen for events on the dock widget being put into a floating dock window
// because this might be called programmatically, so the dock widget might have never been
// parented to our m_mainWindow initially, so it won't already have an event filter,
// which will prevent the docking functionality from working.
dock->installEventFilter(this);
}
}
@@ -119,9 +119,7 @@ namespace EMStudio
mDock->setFeatures(features);
// mDock->setFloating( true );
mainWindow->addDockWidget(Qt::RightDockWidgetArea, mDock);
mainWindow->setTabPosition(Qt::AllDockWidgetAreas, QTabWidget::North); // put tabs on top?
return mDock;
}
@@ -139,4 +137,4 @@ namespace EMStudio
return widget;
}
} // namespace EMStudio
} // namespace EMStudio