diff --git a/src/util/imgui_fullscreen.cpp b/src/util/imgui_fullscreen.cpp index 62d77317d..a8784b428 100644 --- a/src/util/imgui_fullscreen.cpp +++ b/src/util/imgui_fullscreen.cpp @@ -675,8 +675,12 @@ ImGuiFullscreen::FocusResetType ImGuiFullscreen::GetQueuedFocusResetType() void ImGuiFullscreen::ForceKeyNavEnabled() { ImGuiContext& g = *ImGui::GetCurrentContext(); - g.ActiveIdSource = (g.ActiveIdSource == ImGuiInputSource_Mouse) ? ImGuiInputSource_Keyboard : g.ActiveIdSource; - g.NavInputSource = (g.NavInputSource == ImGuiInputSource_Mouse) ? ImGuiInputSource_Keyboard : g.ActiveIdSource; + g.ActiveIdSource = (g.ActiveIdSource == ImGuiInputSource_Mouse || g.ActiveIdSource == ImGuiInputSource_None) ? + ImGuiInputSource_Keyboard : + g.ActiveIdSource; + g.NavInputSource = (g.NavInputSource == ImGuiInputSource_Mouse || g.NavInputSource == ImGuiInputSource_None) ? + ImGuiInputSource_Keyboard : + g.ActiveIdSource; g.NavDisableHighlight = false; g.NavDisableMouseHover = true; }