[Mac] Fix Mouse.GetState() h-wheel

External mice will now report horizontal scrolling in the low-level
`Mouse.GetState()` API. The touchpad apparently creates an emulated
mouse device that does not report horizontal wheel scrolling events.

Touchpad support probably requires a proper multitouch implementation.
This commit is contained in:
thefiddler 2014-06-10 17:43:31 +02:00
parent 5e63c5fa5c
commit 8373782fad

View file

@ -413,6 +413,11 @@ namespace OpenTK.Platform.MacOS
mouse.State.Y += v_int;
break;
case HIDUsageGD.Z:
// Horizontal scrolling for apple mouse (old-style with trackball)
mouse.State.SetScrollRelative(v_int, 0);
break;
case HIDUsageGD.Wheel:
mouse.State.SetScrollRelative(0, v_int);
break;