mirror of
https://github.com/ocornut/imgui.git
synced 2026-09-28 04:03:28 +03:00
Nav, Popups: fixed context menu activation with gamepad erroneously testing for _NavEnableKeyboard instead of _NavEnableGamepad. (#9454)
cc: #8803, #9270
This commit is contained in:
parent
d15966ff6c
commit
b2377d616d
2 changed files with 4 additions and 1 deletions
|
|
@ -14356,7 +14356,7 @@ static void ImGui::NavUpdateContextMenuRequest()
|
|||
ImGuiContext& g = *GImGui;
|
||||
g.NavOpenContextMenuItemId = g.NavOpenContextMenuWindowId = 0;
|
||||
const bool nav_keyboard_active = (g.IO.ConfigFlags & ImGuiConfigFlags_NavEnableKeyboard) != 0;
|
||||
const bool nav_gamepad_active = (g.IO.ConfigFlags & ImGuiConfigFlags_NavEnableKeyboard) != 0;
|
||||
const bool nav_gamepad_active = (g.IO.ConfigFlags & ImGuiConfigFlags_NavEnableGamepad) != 0;
|
||||
if ((!nav_keyboard_active && !nav_gamepad_active) || g.NavWindow == NULL)
|
||||
return;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue