From 51d4b26e3df136ad58826fa5a44aaf5917a3f63a Mon Sep 17 00:00:00 2001 From: Sri Sham Haran Date: Sat, 4 Mar 2023 10:37:01 +0800 Subject: [PATCH] off mouse centering on pause/stop --- SHADE_Engine/src/Editor/SHEditor.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/SHADE_Engine/src/Editor/SHEditor.cpp b/SHADE_Engine/src/Editor/SHEditor.cpp index cfdfbbd9..0ee3dfc0 100644 --- a/SHADE_Engine/src/Editor/SHEditor.cpp +++ b/SHADE_Engine/src/Editor/SHEditor.cpp @@ -55,6 +55,7 @@ #include "Scene/SHSceneManager.h" #include "Serialization/SHSerialization.h" #include "Tools/SHDebugDraw.h" +#include "Input/SHInputManager.h" RTTR_REGISTRATION { @@ -634,6 +635,7 @@ namespace SHADE }; editorState = State::PAUSE; SHWindow::SetMouseVisible(true); + SHInputManager::SetMouseCentering(false); SHEventManager::BroadcastEvent(STATE_CHANGE_EVENT, SH_EDITOR_ON_PAUSE_EVENT); } @@ -647,6 +649,7 @@ namespace SHADE }; editorState = SHEditor::State::STOP; SHWindow::SetMouseVisible(true); + SHInputManager::SetMouseCentering(false); SHCommandManager::SwapStacks(); SHEventManager::BroadcastEvent(STATE_CHANGE_EVENT, SH_EDITOR_ON_STOP_EVENT);