]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix horizontal wheel events on Haiku
authorPo Lu <luangruo@yahoo.com>
Sun, 21 Nov 2021 12:43:53 +0000 (12:43 +0000)
committerPo Lu <luangruo@yahoo.com>
Sun, 21 Nov 2021 12:43:53 +0000 (12:43 +0000)
* src/haikuterm.c (haiku_read_socket): Fix modifier
calculation for horizontal wheel events.

src/haikuterm.c

index 6304d9bcd3c34ae21a73c24a6340f45b725d02b2..67c202d97a2b5802432b4a9b46845dae5505ca1b 100644 (file)
@@ -3025,7 +3025,10 @@ haiku_read_socket (struct terminal *terminal, struct input_event *hold_quit)
                                  make_float (py));
                XSETFRAME (inev.frame_or_window, f);
 
-               inev.modifiers |= signbit (py) ? up_modifier : down_modifier;
+               inev.modifiers |= (signbit (inev.kind == HORIZ_WHEEL_EVENT
+                                           ? px : py)
+                                  ? up_modifier
+                                  : down_modifier);
                py = 0.0f;
                px = 0.0f;
              }