<html>
    <head>
      <base href="https://bugs.freedesktop.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - libinput ignores gen1 magicmouse touch-scroll and middle click"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=109087">109087</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>libinput ignores gen1 magicmouse touch-scroll and middle click
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>Wayland
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>x86-64 (AMD64)
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>Linux (All)
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>XWayland
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>wayland-bugs@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>rburcham@pinsightmedia.com
          </td>
        </tr>

        <tr>
          <th>QA Contact</th>
          <td>xorg-team@lists.x.org
          </td>
        </tr></table>
      <p>
        <div>
        <pre>I have been unable to drive a bluetooth gen-1 magicmouse as anything other than
a stock 2-button mouse.  Regardless of config or params libinput refuses to
register events for middle button or any touch v-scroll and h-scroll actions.

hid_magicmouse is driving the device: 

[Tue Nov 13 08:40:35 2018] magicmouse 0005:05AC:030D.0005: unknown main item
tag 0x0 
[Tue Nov 13 08:40:35 2018] input: rburcham’s Mouse as
/devices/virtual/misc/uhid/0005:05AC:030D.0005/input/input25 
[Tue Nov 13 08:40:35 2018] magicmouse 0005:05AC:030D.0005: input,hidraw4:
BLUETOOTH HID v3.06 Mouse [rburcham’s Mouse] on [redacted]

hid_magicmouse is reporting the params: 

$ grep "" /sys/module/hid_magicmouse/parameters/* 
/sys/module/hid_magicmouse/parameters/emulate_3button:Y 
/sys/module/hid_magicmouse/parameters/emulate_scroll_wheel:Y 
/sys/module/hid_magicmouse/parameters/report_undeciphered:N 
/sys/module/hid_magicmouse/parameters/scroll_acceleration:N 
/sys/module/hid_magicmouse/parameters/scroll_speed:32 

Whether driven in xorg via evdev or via libinput (shown here) the driver
reports enabled capabilities:

$ xinput list-props 19
Device 'rburcham’s Mouse':
        Device Enabled (155):   1
        Coordinate Transformation Matrix (157): 1.000000, 0.000000, 0.000000,
0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
        libinput Natural Scrolling Enabled (298):       0
        libinput Natural Scrolling Enabled Default (299):       0
        libinput Scroll Methods Available (302):        0, 0, 1
        libinput Scroll Method Enabled (303):   0, 0, 1
        libinput Scroll Method Enabled Default (304):   0, 0, 0
        libinput Button Scrolling Button (311): 2
        libinput Button Scrolling Button Default (312): 2
        libinput Middle Emulation Enabled (313):        1
        libinput Middle Emulation Enabled Default (314):        0
        libinput Accel Speed (305):     0.000000
        libinput Accel Speed Default (306):     0.000000
        libinput Accel Profiles Available (315):        1, 1
        libinput Accel Profile Enabled (316):   1, 0
        libinput Accel Profile Enabled Default (317):   1, 0
        libinput Calibration Matrix (318):      1.000000, 0.000000, 0.000000,
0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
        libinput Calibration Matrix Default (319):      1.000000, 0.000000,
0.000000, 0.000000, 1.000000, 0.000000, 0.000000, 0.000000, 1.000000
        libinput Left Handed Enabled (307):     0
        libinput Left Handed Enabled Default (308):     0
        libinput Send Events Modes Available (275):     1, 0
        libinput Send Events Mode Enabled (276):        0, 0
        libinput Send Events Mode Enabled Default (277):        0, 0
        Device Node (278):      "/dev/input/event21"
        Device Product ID (279):        1452, 781
        libinput Drag Lock Buttons (309):       <no items>
        libinput Horizontal Scroll Enabled (310):       1

But libinput debug-events doesn't register any event for touch-scrolling or
middle clicking:

$ libinput debug-events
-event3   DEVICE_ADDED     Power Button                      seat0 default
group1  cap:k
-event11  DEVICE_ADDED     Video Bus                         seat0 default
group2  cap:k
-event1   DEVICE_ADDED     Power Button                      seat0 default
group3  cap:k
-event0   DEVICE_ADDED     Lid Switch                        seat0 default
group4  cap:S
-event2   DEVICE_ADDED     Sleep Button                      seat0 default
group5  cap:k
-event13  DEVICE_ADDED     HDA NVidia HDMI/DP,pcm=3          seat0 default
group6  cap:
-event14  DEVICE_ADDED     HDA NVidia HDMI/DP,pcm=7          seat0 default
group6  cap:
-event15  DEVICE_ADDED     HDA NVidia HDMI/DP,pcm=8          seat0 default
group6  cap:
-event16  DEVICE_ADDED     HDA NVidia HDMI/DP,pcm=9          seat0 default
group6  cap:
-event5   DEVICE_ADDED     Apple Inc. Apple Keyboard         seat0 default
group7  cap:k
-event6   DEVICE_ADDED     Apple Inc. Apple Keyboard         seat0 default
group7  cap:k
-event9   DEVICE_ADDED     Integrated_Webcam_HD: Integrate   seat0 default
group8  cap:k
-event18  DEVICE_ADDED     DELL0832:00 044E:1220 Mouse       seat0 default
group9  cap:p left scroll-nat scroll-button
-event19  DEVICE_ADDED     DELL0832:00 044E:1220 Touchpad    seat0 default
group9  cap:pg  size 100x53mm tap(dl off) left scroll-nat scroll-2fg-edge
dwt-on
-event20  DEVICE_ADDED     DELL0832:00 044E:1220 UNKNOWN     seat0 default
group9  cap:k
-event17  DEVICE_ADDED     HDA Intel PCH Headphone Mic       seat0 default
group6  cap:
-event7   DEVICE_ADDED     Intel HID events                  seat0 default
group10 cap:k
-event8   DEVICE_ADDED     Intel HID 5 button array          seat0 default
group11 cap:k
-event12  DEVICE_ADDED     Dell WMI hotkeys                  seat0 default
group12 cap:k
-event4   DEVICE_ADDED     AT Translated Set 2 keyboard      seat0 default
group13 cap:k
-event21  DEVICE_ADDED     rburcham’s Mouse                  seat0 default
group14 cap:p  size 91x52mm left scroll-nat calib scroll-button
<attempting vertical and horizontal touch-scrolls, no events register...>
<attempting some middle-clicks, only lefts and rights register...>
 event21  POINTER_BUTTON   +12.76s      BTN_LEFT (272) pressed, seat count: 1
 event21  POINTER_BUTTON   +12.88s      BTN_LEFT (272) released, seat count: 0
 event21  POINTER_BUTTON   +16.63s      BTN_RIGHT (273) pressed, seat count: 1
 event21  POINTER_BUTTON   +16.79s      BTN_RIGHT (273) released, seat count: 0
 event21  POINTER_BUTTON   +19.82s      BTN_RIGHT (273) pressed, seat count: 1
 event21  POINTER_BUTTON   +19.98s      BTN_RIGHT (273) released, seat count: 0
 event21  POINTER_BUTTON   +21.36s      BTN_RIGHT (273) pressed, seat count: 1
 event21  POINTER_BUTTON   +21.50s      BTN_RIGHT (273) released, seat count: 0
 event21  POINTER_MOTION   +28.56s        0.23/  0.23 ( +1.00/ +1.00)
 event21  POINTER_MOTION   +28.57s        0.00/  0.44 ( +0.00/ +1.00)
 event21  POINTER_MOTION   +28.58s        0.00/  0.64 ( +0.00/ +1.00)
 event21  POINTER_MOTION   +28.59s        0.71/  0.71 ( +1.00/ +1.00)
 event21  POINTER_MOTION   +28.60s        0.00/  0.71 ( +0.00/ +1.00)
 event21  POINTER_MOTION   +29.25s       -1.33/  0.44 ( -3.00/ +1.00)
 event21  POINTER_MOTION   +29.27s       -2.05/  0.00 ( -3.00/ +0.00)
 event21  POINTER_MOTION   +29.28s       -1.54/  0.00 ( -2.00/ +0.00)
 event21  POINTER_MOTION   +29.29s       -1.54/  0.00 ( -2.00/ +0.00)
 event21  POINTER_MOTION   +29.30s       -2.31/  0.00 ( -3.00/ +0.00)
 event21  POINTER_MOTION   +29.31s       -1.54/  0.00 ( -2.00/ +0.00)
 event21  POINTER_MOTION   +29.32s       -1.54/  0.00 ( -2.00/ +0.00)
 event21  POINTER_MOTION   +29.33s       -0.75/  0.00 ( -1.00/ +0.00)
 event21  POINTER_MOTION   +29.36s       -0.53/  0.00 ( -1.00/ +0.00)
 event21  POINTER_MOTION   +29.37s       -0.54/  0.00 ( -1.00/ +0.00)
 event21  POINTER_MOTION   +29.39s       -0.54/  0.00 ( -1.00/ +0.00)
 event21  POINTER_MOTION   +29.41s       -0.47/  0.47 ( -1.00/ +1.00)
 event21  POINTER_MOTION   +29.50s       -0.40/  0.00 ( -1.00/ +0.00)
-event5   KEYBOARD_KEY     +35.49s      *** (-1) pressed
 event5   KEYBOARD_KEY     +37.21s      *** (-1) pressed

This device used to operate flawlessly, with full touch h-scroll and v-scroll
and middle click.

This is on Gentoo with kernel 4.19.8, xorg-x11-7.4-r3, xorg-server-1.20.3,
libinput-1.12.3, xf86-input-libinput-0.28.1.  I've tried previous kernels back
to 4.3 and libinputs back to 1.11.3 and 1.10.7.</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>