Encode horizontal scroll events (AC Pan) as button presses (bit 5 and 6)
Submitted by: David Demelier demelier dot david at gmail dot com MFC after: 1 week
This commit is contained in:
parent
c211af0352
commit
a28cc643b1
@ -229,6 +229,17 @@ hid_interrupt(bthid_session_p s, uint8_t *data, int32_t len)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
switch (usage) {
|
switch (usage) {
|
||||||
|
case HUC_AC_PAN:
|
||||||
|
/* Horizontal scroll */
|
||||||
|
if (val < 0)
|
||||||
|
mouse_butt |= (1 << 5);
|
||||||
|
else
|
||||||
|
mouse_butt |= (1 << 6);
|
||||||
|
|
||||||
|
mevents ++;
|
||||||
|
val = 0;
|
||||||
|
break;
|
||||||
|
|
||||||
case 0xb5: /* Scan Next Track */
|
case 0xb5: /* Scan Next Track */
|
||||||
val = 0x19;
|
val = 0x19;
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user