Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tweak(console): Improve keyboard focus #2886

Conversation

tens0rfl0w
Copy link
Contributor

@tens0rfl0w tens0rfl0w commented Oct 28, 2024

Goal of this PR

This improves the focus logic of the text input field in the client console. We now focus the input field when:

  • Opening the console
  • Hovering over the input field
  • Whenever the console gains focus and no other clickable or input-taking item is active

How is this PR achieving the goal

Changing the focus logic for the console input field.

This PR applies to the following area(s)

FiveM, RedM

Successfully tested on

Game builds: Not applicable

Platforms: Windows (Client)

Checklist

  • Code compiles and has been tested successfully.
  • Code explains itself well and/or is documented.
  • My commit message explains what the changes do and what they are for.
  • No extra compilation warnings are added by these changes.

Fixes issues

fixes #2887

This improves the focusing of the text input field in the client console.
We now focus the input field when:
- Opening the console
- Hovering over the input field
- Whenever the console gains focus and no other clickable or input-taking item is active
@github-actions github-actions bot added RedM Issues/PRs related to RedM invalid Requires changes before it's considered valid and can be (re)triaged labels Oct 28, 2024
@PeekerJ
Copy link

PeekerJ commented Oct 28, 2024

Please merge immediately, last merged commit that unfocuses input is a massive L

@prikolium-cfx prikolium-cfx added ready-to-merge This PR is enqueued for merging and removed invalid Requires changes before it's considered valid and can be (re)triaged labels Oct 28, 2024
@github-actions github-actions bot added the invalid Requires changes before it's considered valid and can be (re)triaged label Oct 28, 2024
@prikolium-cfx prikolium-cfx removed the invalid Requires changes before it's considered valid and can be (re)triaged label Oct 29, 2024
@prikolium-cfx prikolium-cfx merged commit 9cac14f into citizenfx:master Oct 29, 2024
4 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge This PR is enqueued for merging RedM Issues/PRs related to RedM
Projects
None yet
Development

Successfully merging this pull request may close these issues.

F8 console does not focus input anymore after a change
3 participants