]> git.eshelyaron.com Git - emacs.git/commitdiff
Stop sending touch-end events if coalescing scroll events
authorPo Lu <luangruo@yahoo.com>
Sun, 2 Jan 2022 03:02:02 +0000 (11:02 +0800)
committerPo Lu <luangruo@yahoo.com>
Sun, 2 Jan 2022 03:02:02 +0000 (11:02 +0800)
* src/xterm.c (handle_one_xevent): Don't generate touch-end
events if mwheel_coalesce_scroll_events is non-nil.

src/xterm.c

index 3c35c275baf64920796a97506af3bf38e3148018..c3443317559aec58519072d3e93744d3e3b349f9 100644 (file)
@@ -10173,12 +10173,12 @@ handle_one_xevent (struct x_display_info *dpyinfo,
                          val->emacs_value += delta;
 
                          if (mwheel_coalesce_scroll_events
-                             && (fabs (val->emacs_value) < 1)
-                             && (fabs (delta) > 0))
+                             && (fabs (val->emacs_value) < 1))
                            continue;
 
                          bool s = signbit (val->emacs_value);
-                         inev.ie.kind = (fabs (delta) > 0
+                         inev.ie.kind = ((mwheel_coalesce_scroll_events
+                                          || fabs (delta) > 0)
                                          ? (val->horizontal
                                             ? HORIZ_WHEEL_EVENT
                                             : WHEEL_EVENT)