Don't disable keyboard when menuBar is shown and gControlNav is true (#1566)

This commit is contained in:
Garrett Cox 2022-09-25 11:14:46 -05:00 committed by GitHub
parent 11b6ce819d
commit da677682cd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -363,7 +363,7 @@ namespace SohImGui {
}
if (CVar_GetS32("gControlNav", 0) && CVar_GetS32("gOpenMenuBar", 0)) {
io->ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad | ImGuiConfigFlags_NavEnableKeyboard;
io->ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad;
} else {
io->ConfigFlags &= ~ImGuiConfigFlags_NavEnableGamepad;
}
@ -466,7 +466,7 @@ namespace SohImGui {
ShowCursor(menu_bar, Dialogues::dMenubar);
Window::GetInstance()->GetControlDeck()->SaveControllerSettings();
if (CVar_GetS32("gControlNav", 0) && CVar_GetS32("gOpenMenuBar", 0)) {
io->ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad | ImGuiConfigFlags_NavEnableKeyboard;
io->ConfigFlags |= ImGuiConfigFlags_NavEnableGamepad;
} else {
io->ConfigFlags &= ~ImGuiConfigFlags_NavEnableGamepad;
}