How does scrolling work on an Apple Magic Mouse

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
ThePC007
Prole
Posts: 36
Joined: Sat Jan 30, 2016 3:00 pm
Contact:

How does scrolling work on an Apple Magic Mouse

Post by ThePC007 »

Hey there,
I'm aware that moving the wheel on a regular mouse triggers the love.wheelmoved(x, y) function, however, I am wondering how Löve would deal with Apple's Magic Mouse running on OS X. Since I do not own a Mac (that isn't a mid-2007 MacBook) and also don't own a Magic Mouse, I obviously cannot test it, which is why I am posting this, in hopes that somebody with a Mac could answer my question. Does love.wheelmoved(x, y) get triggered when the user is sliding his finger across his Magic Mouse? And if yes, do the x and y values actually correspond to the distance/speed of the slide?

ThePC007
Löve is love, Löve is life.
JaredSartin
Prole
Posts: 9
Joined: Wed Jul 09, 2014 2:22 pm

Re: How does scrolling work on an Apple Magic Mouse

Post by JaredSartin »

Post a Love file or code to run and the instructions for what you want in return, I have access to the hardware.
User avatar
ThePC007
Prole
Posts: 36
Joined: Sat Jan 30, 2016 3:00 pm
Contact:

Re: How does scrolling work on an Apple Magic Mouse

Post by ThePC007 »

Here you go. It's quite simple: You move your mouse wheel and it draws a text showing you the x and y values that the love.wheelmoved(x, y) callback has generated.
Attachments
scroll.love
(340 Bytes) Downloaded 120 times
Löve is love, Löve is life.
Post Reply

Who is online

Users browsing this forum: Amazon [Bot], Bing [Bot] and 3 guests