Skip to content

Commit

Permalink
Addition to more proper mouse clicks simulation (#943)
Browse files Browse the repository at this point in the history
This is an addition to 57252ec
  • Loading branch information
Xottab-DUTY committed Jan 19, 2025
1 parent 3fb66c7 commit a8f7417
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/xrGame/UIDialogHolder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ bool CDialogHolder::IR_UIOnKeyboardPress(int dik)
if (TIR->OnKeyboardAction(dik, WINDOW_KEY_PRESSED))
return true;

if (dik > XR_CONTROLLER_BUTTON_INVALID && dik < XR_CONTROLLER_BUTTON_MAX)
if (UI().GetUICursor().IsVisible() && dik > XR_CONTROLLER_BUTTON_INVALID && dik < XR_CONTROLLER_BUTTON_MAX)
{
FocusDirection direction = FocusDirection::Same;
switch (GetBindedAction(dik, EKeyContext::UI))
Expand All @@ -341,8 +341,8 @@ bool CDialogHolder::IR_UIOnKeyboardPress(int dik)
if (candidate || candidate2)
{
focus.SetFocused(candidate ? candidate : candidate2);
return true;
}
return true;
}
}

Expand Down

0 comments on commit a8f7417

Please sign in to comment.