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

[cmds] Fix mouse release bug in paint event code #2261

Merged
merged 2 commits into from
Mar 17, 2025
Merged

[cmds] Fix mouse release bug in paint event code #2261

merged 2 commits into from
Mar 17, 2025

Conversation

ghaerr
Copy link
Owner

@ghaerr ghaerr commented Mar 17, 2025

Fixes occasional problem where mouse button up processing was delayed until after next mouse movement in portable event code used in paint.

Also adds 'm' command to paint to switch between 16x16 and 8x8 mouse cursor for slow systems. Discussed with @toncho11 in #2259 (comment).

paint main loop moved from polling to hanging on select for all events, thus reducing CPU load for any other applications running.

Event code cleaned up and mouse position returned in all events. This code will be ported back to 8086-toolchain/examples in the future.

@ghaerr ghaerr merged commit a0f3092 into master Mar 17, 2025
1 check passed
@ghaerr ghaerr deleted the mouse branch March 17, 2025 22:59
@toncho11
Copy link
Contributor

Drawing is probably a bit slow so the user tend to keep mouse down and moving. So after releasing the mouse button paint continues to draw for 1 or 2 seconds more on my Amstrad because of the extra buffered events.

Also ctrl+z will be usefull to remove the last mouse down until mouse up (the last drawing).

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.

2 participants