Account for mouse wheel speed settings on Windows
- [x] Tested on all platforms changed
- [x] Added an entry to the
changelogmodule if knowledge of this change could be valuable to users - [x] Updated documentation to reflect any user-facing changes, including notes of platform-specific behavior
- [x] Created or updated an example program if it would help users understand this functionality
Fix WindowEvent::MouseWheel doesn't account for mouse wheel speed settings
Reference docs: https://learn.microsoft.com/en-us/windows/win32/inputdev/about-mouse-input#determining-the-number-of-scroll-lines Reference tao PR: https://github.com/tauri-apps/tao/pull/1119
Is it something that should be done unconditionally.
For the context. We have in alacritty a setting to adjust that as well, and I'm pretty sure that it'll just start multiplying. Maybe that should be as an option, so users can opt out, and thus can deal with precise by line scrolling if they need to?
I'm fine with making this optional, where do you think I should put the option at and do you think this should be opt-in or opt-out?
I'm fine with making this optional, where do you think I should put the option at and do you think this should be opt-in or opt-out?
maybe a method on the ActiveEventLoop for windows to toggle the behavior?
Since this can be toggled per window, should we put this in WindowExtWindows or go with a new trait ActiveEventLoopExtWindows?
I'm not sure it really matters for per-window level if you can not focus more than one window at the time. Generally could be fine.
I think there might be cases where only some windows will need to get the wheel data without the system settings, so have gone ahead and pushed it to WindowExtWindows
No, I mean, only a single window can receive input at a time, so you can adjust the behavior on focus change.
Yeah, I get what you meant, but that's a bit tedious to use, no? 🙃 (also I believe you can scroll on non focused windows with a system setting that is on by default)
Yeah, I get what you meant, but that's a bit tedious to use, no? 🙃 (also I believe you can scroll on non focused windows with a system setting that is on by default)
I meant pointer focus here, it's a separate thing.
I meant pointer focus here, it's a separate thing.
Ah, right right, makes sense then
I'd probably also add a window attributes method then.
Added