aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPo Lu2022-02-19 16:21:51 +0800
committerPo Lu2022-02-19 16:21:51 +0800
commite015dc77f5e38d52bb0b328c764c8186c8c9bf73 (patch)
tree141099413f5b5ad79a3d7461893b0c0ba5277714 /src
parent76ee4dc82375893a5c59c63acda43af27879e54a (diff)
downloademacs-e015dc77f5e38d52bb0b328c764c8186c8c9bf73.tar.gz
emacs-e015dc77f5e38d52bb0b328c764c8186c8c9bf73.zip
Don't ignore events from XI2 slave devices anymore
All the machinery needed to keep track of events from those devices is already in place, so that's no longer required. * src/xterm.c (x_get_scroll_valuator_delta): (xi_reset_scroll_valuators_for_device_id): (handle_one_xevent): Don't ignore XI devices that are not master pointers or keyboards.
Diffstat (limited to 'src')
-rw-r--r--src/xterm.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/xterm.c b/src/xterm.c
index af456389aba..2dc420a8dee 100644
--- a/src/xterm.c
+++ b/src/xterm.c
@@ -689,7 +689,7 @@ x_get_scroll_valuator_delta (struct x_display_info *dpyinfo, int device_id,
689 { 689 {
690 struct xi_device_t *device = &dpyinfo->devices[i]; 690 struct xi_device_t *device = &dpyinfo->devices[i];
691 691
692 if (device->device_id == device_id && device->master_p) 692 if (device->device_id == device_id)
693 { 693 {
694 for (int j = 0; j < device->scroll_valuator_count; ++j) 694 for (int j = 0; j < device->scroll_valuator_count; ++j)
695 { 695 {
@@ -803,7 +803,7 @@ xi_reset_scroll_valuators_for_device_id (struct x_display_info *dpyinfo, int id,
803 struct xi_device_t *device = xi_device_from_id (dpyinfo, id); 803 struct xi_device_t *device = xi_device_from_id (dpyinfo, id);
804 struct xi_scroll_valuator_t *valuator; 804 struct xi_scroll_valuator_t *valuator;
805 805
806 if (!device || !device->master_p) 806 if (!device)
807 return; 807 return;
808 808
809 if (!device->scroll_valuator_count) 809 if (!device->scroll_valuator_count)
@@ -11314,7 +11314,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
11314 11314
11315 device = xi_device_from_id (dpyinfo, xev->deviceid); 11315 device = xi_device_from_id (dpyinfo, xev->deviceid);
11316 11316
11317 if (!device || !device->master_p) 11317 if (!device)
11318 goto XI_OTHER; 11318 goto XI_OTHER;
11319 11319
11320 bv.button = xev->detail; 11320 bv.button = xev->detail;
@@ -11487,7 +11487,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
11487 11487
11488 device = xi_device_from_id (dpyinfo, xev->deviceid); 11488 device = xi_device_from_id (dpyinfo, xev->deviceid);
11489 11489
11490 if (!device || !device->master_p) 11490 if (!device)
11491 goto XI_OTHER; 11491 goto XI_OTHER;
11492 11492
11493#if defined (USE_X_TOOLKIT) || defined (USE_GTK) 11493#if defined (USE_X_TOOLKIT) || defined (USE_GTK)
@@ -12132,7 +12132,7 @@ handle_one_xevent (struct x_display_info *dpyinfo,
12132 XIGesturePinchEvent *pev = (XIGesturePinchEvent *) xi_event; 12132 XIGesturePinchEvent *pev = (XIGesturePinchEvent *) xi_event;
12133 struct xi_device_t *device = xi_device_from_id (dpyinfo, pev->deviceid); 12133 struct xi_device_t *device = xi_device_from_id (dpyinfo, pev->deviceid);
12134 12134
12135 if (!device || !device->master_p) 12135 if (!device)
12136 goto XI_OTHER; 12136 goto XI_OTHER;
12137 12137
12138#ifdef HAVE_XWIDGETS 12138#ifdef HAVE_XWIDGETS