mirror of
https://github.com/overte-org/overte.git
synced 2025-04-25 17:35:45 +02:00
Fix OpenVR shutdown crash
This commit is contained in:
parent
1cf89f046c
commit
d6d7e67ca3
1 changed files with 8 additions and 8 deletions
|
@ -1060,6 +1060,14 @@ void Application::showCursor(const QCursor& cursor) {
|
||||||
void Application::aboutToQuit() {
|
void Application::aboutToQuit() {
|
||||||
emit beforeAboutToQuit();
|
emit beforeAboutToQuit();
|
||||||
|
|
||||||
|
foreach(auto inputPlugin, PluginManager::getInstance()->getInputPlugins()) {
|
||||||
|
QString name = inputPlugin->getName();
|
||||||
|
QAction* action = Menu::getInstance()->getActionForOption(name);
|
||||||
|
if (action->isChecked()) {
|
||||||
|
inputPlugin->deactivate();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
getActiveDisplayPlugin()->deactivate();
|
getActiveDisplayPlugin()->deactivate();
|
||||||
|
|
||||||
_aboutToQuit = true;
|
_aboutToQuit = true;
|
||||||
|
@ -1149,14 +1157,6 @@ Application::~Application() {
|
||||||
|
|
||||||
ModelEntityItem::cleanupLoadedAnimations();
|
ModelEntityItem::cleanupLoadedAnimations();
|
||||||
|
|
||||||
foreach(auto inputPlugin, PluginManager::getInstance()->getInputPlugins()) {
|
|
||||||
QString name = inputPlugin->getName();
|
|
||||||
QAction* action = Menu::getInstance()->getActionForOption(name);
|
|
||||||
if (action->isChecked()) {
|
|
||||||
inputPlugin->deactivate();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// remove avatars from physics engine
|
// remove avatars from physics engine
|
||||||
DependencyManager::get<AvatarManager>()->clearOtherAvatars();
|
DependencyManager::get<AvatarManager>()->clearOtherAvatars();
|
||||||
VectorOfMotionStates motionStates;
|
VectorOfMotionStates motionStates;
|
||||||
|
|
Loading…
Reference in a new issue