mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-15 09:13:13 +02:00
Nav: keyboard/gamepad activation mark widgets as held to give better visual feedback.
This commit is contained in:
@ -666,7 +666,9 @@ bool ImGui::ButtonBehavior(const ImRect& bb, ImGuiID id, bool* out_hovered, bool
|
||||
else if (g.ActiveIdSource == ImGuiInputSource_Keyboard || g.ActiveIdSource == ImGuiInputSource_Gamepad)
|
||||
{
|
||||
// When activated using Nav, we hold on the ActiveID until activation button is released
|
||||
if (g.NavActivateDownId != id)
|
||||
if (g.NavActivateDownId == id)
|
||||
held = true;
|
||||
else
|
||||
ClearActiveID();
|
||||
}
|
||||
if (pressed)
|
||||
|
Reference in New Issue
Block a user