it almost works for me with ubuntu 18.04.
kernel 4.15.0-13-generic
module mac_hid
Device Enabled (142): 1
Coordinate Transformation Matrix (144): 1.000000, 0.000000, 0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
libinput Natural Scrolling Enabled (277): 0
libinput Natural Scrolling Enabled Default (278): 0
libinput Scroll Methods Available (279): 0, 0, 1
libinput Scroll Method Enabled (280): 0, 0, 1
libinput Scroll Method Enabled Default (281): 0, 0, 0
libinput Button Scrolling Button (282): 3
libinput Button Scrolling Button Default (283): 3
libinput Accel Speed (284): -0.237410
libinput Accel Speed Default (285): 0.000000
libinput Accel Profiles Available (286): 1, 1
libinput Accel Profile Enabled (287): 1, 0
libinput Accel Profile Enabled Default (288): 1, 0
libinput Send Events Modes Available (262): 1, 0
libinput Send Events Mode Enabled (263): 0, 0
libinput Send Events Mode Enabled Default (264): 0, 0
Device Node (265): "/dev/input/event22"
Device Product ID (266): 76, 617
libinput Drag Lock Buttons (291): <no items>
libinput Horizontal Scroll Enabled (292): 1
libinput Scroll Method Enabled (280): 0, 0, 1
initially was 0, 0, 0
. After changing to 0, 0, 1
clicking and holding right button enables scroll by moving the mouse
I see this behavior with current versions of VirtualBox (6.0.12). It seems to occur only when using the laptop screen, which is a touchscreen. The problem goes away once the touchscreen is disabled in the laptop's firmware/BIOS screens.
The problem affects not only the guest VM (Windows) but the VirtualBox manager UI even when no VMs are running.
This problem does not occur when using an external non-touchscreen monitor.
Best Answer
I too got myself a Magic Mouse 2 about 6 weeks ago. You can teach Linux to recognise the Magic Mouse 2 and load the hid_magicmouse module (as it would for the original Magic Mouse and Trackpad) by modifying the udev and modprobe configs. The touch protocols have changed from the MM1 so the MM2 is still just a 2-button device at this time. In my spare time, I am working on decoding how the driver should set up the MM2 but it is a slow process. I have documented what I have so far on a Github project at https://github.com/biggreenogre/mm2. I'm working with Ubuntu Trusty but, since this is in the kernel, it should apply to most recent releases and distros.
Regards,
Drew