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

Pass button press events to guest side if gaining focus in seamless mode #3296

Merged
merged 1 commit into from
Dec 31, 2023

Conversation

FeralChild64
Copy link
Collaborator

@FeralChild64 FeralChild64 commented Dec 31, 2023

Description

Provide a hint to the SDL library, resulting in a better seamless mouse integration behavior; see the Manual testing chapter for the use case.

Thanks to @Torinde for signaling the problem.

Related issues

#3290

Manual testing

  • set mouse_capture to seamless, run DOSBox in a window
  • launch DOS Navigator, Norton Commander, or other program having menus
  • click outside of of the DOSBox window, so that it loses the focus
  • click on the DOS navigator menu - even the first click, when DOSBox window has no focus yet, should be now passed to the guest software (before the PR the results were OS-dependent; on Linux with X11 and KDE the behavior was random, on Windows 11 the first mouse click was never propagated to guest)

Checklist

I have:

  • followed the project's contributing guidelines and code of conduct.
  • performed a self-review of my code.
  • commented on the particularly hard-to-understand areas of my code.
  • split my work into well-defined, bisectable commits, and I named my commits well.
  • applied the appropriate labels (bug, enhancement, refactoring, documentation, etc.)
  • checked that all my commits can be built.
  • confirmed that my code does not cause performance regressions (e.g., by running the Quake benchmark).
  • added unit tests where applicable to prove the correctness of my code and to avoid future regressions.
  • made corresponding changes to the documentation or the website according to the documentation guidelines.
  • locally verified my website or documentation changes.

@FeralChild64 FeralChild64 added bug Something isn't working backport Important fixes that should be backported labels Dec 31, 2023
@FeralChild64 FeralChild64 self-assigned this Dec 31, 2023
@FeralChild64 FeralChild64 marked this pull request as ready for review December 31, 2023 12:07
Copy link
Member

@kcgen kcgen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice find, @FeralChild64 !

@Torinde
Copy link
Contributor

Torinde commented Dec 31, 2023

Tested the fix, it works, thanks @FeralChild64!

@FeralChild64 FeralChild64 merged commit 998a3ef into main Dec 31, 2023
40 checks passed
@FeralChild64 FeralChild64 deleted the fc/seamless-mouse-capture-event-1 branch February 3, 2024 16:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport Important fixes that should be backported bug Something isn't working
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

None yet

3 participants