diff options
| author | Po Lu | 2022-05-27 10:34:04 +0800 |
|---|---|---|
| committer | Po Lu | 2022-05-27 10:34:04 +0800 |
| commit | bb0317442b4d62108ca40cc396f5ced467c55f25 (patch) | |
| tree | 84977fda69bd2027141366e2dd209bb4e9a2abab /src | |
| parent | c0807daedc22812add26f9f9be8d9b68afac1217 (diff) | |
| download | emacs-bb0317442b4d62108ca40cc396f5ced467c55f25.tar.gz emacs-bb0317442b4d62108ca40cc396f5ced467c55f25.zip | |
Fix XI scroll valuator reset on X Toolkit builds
* src/xterm.c (handle_one_xevent): Reset valuators on XI_Leave
if leave->event is an edit widget as well.
Diffstat (limited to 'src')
| -rw-r--r-- | src/xterm.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/xterm.c b/src/xterm.c index 5964a8bb483..4f264ab2a86 100644 --- a/src/xterm.c +++ b/src/xterm.c | |||
| @@ -17841,6 +17841,16 @@ handle_one_xevent (struct x_display_info *dpyinfo, | |||
| 17841 | masks are set on the frame widget's window. */ | 17841 | masks are set on the frame widget's window. */ |
| 17842 | f = x_window_to_frame (dpyinfo, leave->event); | 17842 | f = x_window_to_frame (dpyinfo, leave->event); |
| 17843 | 17843 | ||
| 17844 | /* Also do this again here, since the test for `any' | ||
| 17845 | above may not have found a frame, as that usually | ||
| 17846 | just looks up a top window on Xt builds. */ | ||
| 17847 | |||
| 17848 | #ifdef HAVE_XINPUT2_1 | ||
| 17849 | if (leave->detail != XINotifyInferior && f) | ||
| 17850 | xi_reset_scroll_valuators_for_device_id (dpyinfo, | ||
| 17851 | leave->deviceid, false); | ||
| 17852 | #endif | ||
| 17853 | |||
| 17844 | if (!f) | 17854 | if (!f) |
| 17845 | f = x_top_window_to_frame (dpyinfo, leave->event); | 17855 | f = x_top_window_to_frame (dpyinfo, leave->event); |
| 17846 | #endif | 17856 | #endif |