Input: Properly swap DevicePresenceNotify events.
This commit is contained in:
parent
31a7994ac7
commit
3b114f2603
|
@ -929,6 +929,8 @@ SEventIDispatch(xEvent * from, xEvent * to)
|
||||||
DO_SWAP(SDeviceMappingNotifyEvent, deviceMappingNotify);
|
DO_SWAP(SDeviceMappingNotifyEvent, deviceMappingNotify);
|
||||||
else if (type == ChangeDeviceNotify)
|
else if (type == ChangeDeviceNotify)
|
||||||
DO_SWAP(SChangeDeviceNotifyEvent, changeDeviceNotify);
|
DO_SWAP(SChangeDeviceNotifyEvent, changeDeviceNotify);
|
||||||
|
else if (type == DevicePresenceNotify)
|
||||||
|
DO_SWAP(SDevicePresenceNotifyEvent, devicePresenceNotify);
|
||||||
else {
|
else {
|
||||||
FatalError("XInputExtension: Impossible event!\n");
|
FatalError("XInputExtension: Impossible event!\n");
|
||||||
}
|
}
|
||||||
|
@ -974,6 +976,7 @@ XInputExtensionInit(void)
|
||||||
EventSwapVector[DeviceButtonStateNotify] = SEventIDispatch;
|
EventSwapVector[DeviceButtonStateNotify] = SEventIDispatch;
|
||||||
EventSwapVector[DeviceMappingNotify] = SEventIDispatch;
|
EventSwapVector[DeviceMappingNotify] = SEventIDispatch;
|
||||||
EventSwapVector[ChangeDeviceNotify] = SEventIDispatch;
|
EventSwapVector[ChangeDeviceNotify] = SEventIDispatch;
|
||||||
|
EventSwapVector[DevicePresenceNotify] = SEventIDispatch;
|
||||||
} else {
|
} else {
|
||||||
FatalError("IExtensionInit: AddExtensions failed\n");
|
FatalError("IExtensionInit: AddExtensions failed\n");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user