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

sokol_app.h html5: event bubbling followup fixes... #972

Closed
floooh opened this issue Jan 22, 2024 · 1 comment
Closed

sokol_app.h html5: event bubbling followup fixes... #972

floooh opened this issue Jan 22, 2024 · 1 comment

Comments

@floooh
Copy link
Owner

floooh commented Jan 22, 2024

The recent fix to simply let bubble mouse and touch events up to the web page has some undesirable side effects:

Related:

Solution: restore previous default behaviour (mouse, touch and maybe key input does not bubble up by default), and instead add the following config items to sapp_desc:

  • html5_bubble_mouse_events
  • html5_bubble_wheel_events
  • html5_bubble_touch_events
  • html5_bubble_key_events
  • html5_bubble_char_events

...this would be a good opportunity (but a breaking change) to introduce nesting for those platform-specific config items, e.g. (still a good idea, but for a later time)

return (sapp_desc){
    .win32 = {
        ...
    },
    .html5 = {
        ...
    }
};
@floooh
Copy link
Owner Author

floooh commented Jan 27, 2024

Fixed via #975

@floooh floooh closed this as completed Jan 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant