mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-06 04:58:47 +02:00
InputText, Nav: fixed repeated calls to SetKeyboardFocusHere() preventing to use InputText(). (#4682)
+ Stack Tool: favor inspecting HoveredID over ActiveID as the later is more likely to be locked.
This commit is contained in:
@ -9717,8 +9717,9 @@ void ImGui::NavMoveRequestApplyResult()
|
||||
}
|
||||
}
|
||||
|
||||
ClearActiveID();
|
||||
g.NavWindow = result->Window;
|
||||
if (g.ActiveId != result->ID)
|
||||
ClearActiveID();
|
||||
if (g.NavId != result->ID)
|
||||
{
|
||||
// Don't set NavJustMovedToId if just landed on the same spot (which may happen with ImGuiNavMoveFlags_AllowCurrentNavId)
|
||||
@ -12188,7 +12189,7 @@ void ImGui::UpdateDebugToolStackQueries()
|
||||
|
||||
// Update queries. The steps are: -1: query Stack, >= 0: query each stack item
|
||||
// We can only perform 1 ID Info query every frame. This is designed so the GetID() tests are cheap and constant-time
|
||||
const ImGuiID query_id = g.ActiveId ? g.ActiveId : g.HoveredIdPreviousFrame;
|
||||
const ImGuiID query_id = g.HoveredIdPreviousFrame ? g.HoveredIdPreviousFrame : g.ActiveId;
|
||||
if (tool->QueryId != query_id)
|
||||
{
|
||||
tool->QueryId = query_id;
|
||||
|
Reference in New Issue
Block a user