This repository was archived by the owner on Jan 5, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -766,6 +766,9 @@ namespace RTE {
766
766
break ;
767
767
}
768
768
case SDL_MOUSEMOTION:
769
+ if (m_DisableMouseMoving) {
770
+ break ;
771
+ }
769
772
m_RawMouseMovement += Vector (static_cast <float >(inputEvent.motion .xrel ), static_cast <float >(inputEvent.motion .yrel ));
770
773
m_AbsoluteMousePos.SetXY (static_cast <float >(inputEvent.motion .x * g_WindowMan.GetResMultiplier ()), static_cast <float >(inputEvent.motion .y * g_WindowMan.GetResMultiplier ()));
771
774
if (g_WindowMan.FullyCoversAllDisplays ()) {
Original file line number Diff line number Diff line change @@ -511,6 +511,8 @@ namespace RTE {
511
511
512
512
void WindowMan::DisplaySwitchIn (SDL_Window *windowThatShouldTakeInputFocus) const {
513
513
g_UInputMan.DisableMouseMoving (false );
514
+ g_UInputMan.DisableKeys (false );
515
+
514
516
if (!m_MultiDisplayWindows.empty ()) {
515
517
for (const auto &window : m_MultiDisplayWindows) {
516
518
SDL_RaiseWindow (window.get ());
@@ -526,6 +528,7 @@ namespace RTE {
526
528
527
529
void WindowMan::DisplaySwitchOut () const {
528
530
g_UInputMan.DisableMouseMoving (true );
531
+ g_UInputMan.DisableKeys (true );
529
532
}
530
533
531
534
// ///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
You can’t perform that action at this time.
0 commit comments