mirror of
https://github.com/Drezil/imgui.git
synced 2024-12-18 06:06:35 +00:00
Nav: Clearing mouse hover flag using MouseClicked[] test instead of MouseDown[] so that invalid mouse button won't keep breaking nav (#323)
This commit is contained in:
parent
695ca7bb45
commit
bf42657850
@ -2817,7 +2817,7 @@ void ImGui::NewFrame()
|
||||
{
|
||||
g.IO.MouseDragMaxDistanceSqr[i] = ImMax(g.IO.MouseDragMaxDistanceSqr[i], ImLengthSqr(g.IO.MousePos - g.IO.MouseClickedPos[i]));
|
||||
}
|
||||
if (g.IO.MouseDown[i]) // Pressing any mouse button reactivate mouse hovering which may have been deactivated by gamepad/keyboard navigation
|
||||
if (g.IO.MouseClicked[i]) // Clicking any mouse button reactivate mouse hovering which may have been deactivated by gamepad/keyboard navigation
|
||||
g.NavDisableMouseHover = false;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user