[Vm-dev] Miss-understanding mousewheel events

Nicolas Cellier nicolas.cellier.aka.nice at gmail.com
Wed Dec 25 23:42:29 UTC 2019

Hi all,
I'm in my way of implementing mousewheel events on windows VM.

If I understand it correctly, we fill the buttons field of the event buffer
with modifiers states, and we don't fill the modifiers field of the event

This sounds very strange to me.
(I've commented the lines that I find questionable)
Eliot, do you remember why?

It gives this image code:

generateMouseWheelEvent: evtBuf
     modifiers := evtBuf fifth.
    buttons := (modifiers bitShift: 3) bitOr: (lastMouseEvent buttons
bitAnd: 7).

while other mouse events are:

generateMouseEvent: evtBuf
     buttons := evtBuf fifth.
     modifiers := evtBuf sixth.

I'd be happy to see more uniformity, sixth field is not used.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20191226/1344e59e/attachment.html>

More information about the Vm-dev mailing list