On recent versions of macOS, or possibly on newer Apple devices, Jitouch does not respond to a newly connected Magic Trackpad or Magic Mouse without reloading all devices.
This is because the Magic Trackpad does not show up as a BNBTrackpadDevice, and the Magic Mouse does not show up as a BNBMouseDevice in the I/O Registry. For example, the output of ioreg -l -w 180 | grep -i BNBTrackpadDevice is empty even with a Magic Trackpad connected.
This prevents Jitouch from detecting when those devices are connected and disconnected, so it can't refresh its device list or add its callback to those devices.
Instead, Jitouch should watch for the connection of I/O devices named AppleMultitouchDevice, which have a Multitouch ID that corresponds to the ID produced by MTDeviceGetDeviceID, and a Family ID that corresponds to the output of MTDeviceGetFamilyID. When such a device is connected, Jitouch's stored device list can be searched by Multitouch ID and the matching device stopped, before starting a new device for that ID.
On recent versions of macOS, or possibly on newer Apple devices, Jitouch does not respond to a newly connected Magic Trackpad or Magic Mouse without reloading all devices.
This is because the Magic Trackpad does not show up as a
BNBTrackpadDevice
, and the Magic Mouse does not show up as aBNBMouseDevice
in the I/O Registry. For example, the output ofioreg -l -w 180 | grep -i BNBTrackpadDevice
is empty even with a Magic Trackpad connected.This prevents Jitouch from detecting when those devices are connected and disconnected, so it can't refresh its device list or add its callback to those devices.
Instead, Jitouch should watch for the connection of I/O devices named
AppleMultitouchDevice
, which have aMultitouch ID
that corresponds to the ID produced byMTDeviceGetDeviceID
, and aFamily ID
that corresponds to the output ofMTDeviceGetFamilyID
. When such a device is connected, Jitouch's stored device list can be searched byMultitouch ID
and the matching device stopped, before starting a new device for that ID.See the IOKitLib API and example ioreg outputs.
Fixes #28 and fixes #40 and fixes #46