Skip to content

Improve -nomousegrab mouse input handling #702

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Lgt2x
Copy link
Member

@Lgt2x Lgt2x commented May 13, 2025

Pull Request Type

  • GitHub Workflow changes
  • Documentation or Wiki changes
  • Build and Dependency changes
  • Runtime changes
    • Render changes
    • Audio changes
    • Input changes
    • Network changes
    • Other changes

Description

Minor fixes to #695 (@tophyr ):

  • event->motion.[x/y]rel is float, so store DDIO_mouse_state.dx as float to avoid losing precision. This is especially needed when mouse is not grabbed by the window (-nomousegrab option) where xrel/yrel does not only have integer values.
  • Remove broken legacy code supporting -nomousegrab mode. Position is still not the same between the actual OS cursor and the in-game cursor, but it is better than it was before.

@Lgt2x Lgt2x changed the title Minor mouse input improvements Improve -nomousegrab mouse input handling May 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant