mirror of
https://github.com/Drezil/imgui.git
synced 2024-11-22 03:47:00 +00:00
Nav: keyboard/gamepad activation mark widgets as held to give better visual feedback.
This commit is contained in:
parent
03417cc77d
commit
d10641b04a
@ -46,6 +46,7 @@ Breaking changes:
|
|||||||
|
|
||||||
Other changes:
|
Other changes:
|
||||||
|
|
||||||
|
- Nav: keyboard/gamepad activation mark widgets as held to give better visual feedback.
|
||||||
- Fixed SetKeyboardFocusHere() not working when current nav focus is in different scope,
|
- Fixed SetKeyboardFocusHere() not working when current nav focus is in different scope,
|
||||||
regression from 1.90.1 related to code scoping Tab presses to local scope. (#7226) [@bratpilz]
|
regression from 1.90.1 related to code scoping Tab presses to local scope. (#7226) [@bratpilz]
|
||||||
- Debug Tools: Metrics: Fixed debug break in SetShortcutRouting() not handling ImGuiMod_Shortcut redirect.
|
- Debug Tools: Metrics: Fixed debug break in SetShortcutRouting() not handling ImGuiMod_Shortcut redirect.
|
||||||
|
@ -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)
|
else if (g.ActiveIdSource == ImGuiInputSource_Keyboard || g.ActiveIdSource == ImGuiInputSource_Gamepad)
|
||||||
{
|
{
|
||||||
// When activated using Nav, we hold on the ActiveID until activation button is released
|
// 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();
|
ClearActiveID();
|
||||||
}
|
}
|
||||||
if (pressed)
|
if (pressed)
|
||||||
|
Loading…
Reference in New Issue
Block a user