Provide additional modifiers as part of the mouse wheel event#895
Provide additional modifiers as part of the mouse wheel event#895xStrom merged 11 commits intolinebender:masterfrom
Conversation
xStrom
left a comment
There was a problem hiding this comment.
Generally looks good. A few inline comments.
1df9673 to
a72a629
Compare
|
Thanks for the review @xStrom! I implemented all the changes you requested in the windows shell, let me know if I understood correctly the changes with LOWORD extracting. |
|
Yeah the let system_delta = HIWORD(wparam as u32) as i16 as f64;
let down_state = LOWORD(wparam as u32) as usize;Then the subsequent use can just be on |
e4f9266 to
4db45bd
Compare
|
I think this is reasonable. The only alternative I can think of is to have some general mechanism that exposes the mouse position, and plumb that through |
d18891b to
076c1cd
Compare
076c1cd to
5dc16b1
Compare
|
@cmyr getting the mouse position through |
As part of the prototype I'm working on I wanted to be able to access the current mouse position as part of mouse wheel events, in order to implement zoom to mouse cursor. Since we already supply shared modifiers between other mouse events, and from following the discussion in #843, it seemed somewhat reasonable to do this by changing
WinHandler::wheelto take aMouseEventlike the other mouse events, and addingwheel_deltatoMouseEvent.I've implemented the changes I am suggesting above as a draft on the windows and GTK backends, but work on the other backends is remaining.