mirror of
https://github.com/stenzek/duckstation.git
synced 2025-06-08 20:45:34 +00:00
ImGuiFullscreen: Default input source to keyboard if none
This commit is contained in:
parent
88e14dd3ff
commit
57ca5dd2c2
@ -675,8 +675,12 @@ ImGuiFullscreen::FocusResetType ImGuiFullscreen::GetQueuedFocusResetType()
|
|||||||
void ImGuiFullscreen::ForceKeyNavEnabled()
|
void ImGuiFullscreen::ForceKeyNavEnabled()
|
||||||
{
|
{
|
||||||
ImGuiContext& g = *ImGui::GetCurrentContext();
|
ImGuiContext& g = *ImGui::GetCurrentContext();
|
||||||
g.ActiveIdSource = (g.ActiveIdSource == ImGuiInputSource_Mouse) ? ImGuiInputSource_Keyboard : g.ActiveIdSource;
|
g.ActiveIdSource = (g.ActiveIdSource == ImGuiInputSource_Mouse || g.ActiveIdSource == ImGuiInputSource_None) ?
|
||||||
g.NavInputSource = (g.NavInputSource == ImGuiInputSource_Mouse) ? ImGuiInputSource_Keyboard : g.ActiveIdSource;
|
ImGuiInputSource_Keyboard :
|
||||||
|
g.ActiveIdSource;
|
||||||
|
g.NavInputSource = (g.NavInputSource == ImGuiInputSource_Mouse || g.NavInputSource == ImGuiInputSource_None) ?
|
||||||
|
ImGuiInputSource_Keyboard :
|
||||||
|
g.ActiveIdSource;
|
||||||
g.NavDisableHighlight = false;
|
g.NavDisableHighlight = false;
|
||||||
g.NavDisableMouseHover = true;
|
g.NavDisableMouseHover = true;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user