From af84ea2b9e6b54d8d0e26773d3299b9efb5a39b0 Mon Sep 17 00:00:00 2001 From: Po Lu Date: Sat, 30 Apr 2022 09:22:20 +0800 Subject: [PATCH] Fix mouse face bugs on Motif * src/xterm.c (handle_one_xevent): Fix handling LeaveNotify events from Motif menus. --- src/xterm.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/xterm.c b/src/xterm.c index 28c435afde3..d442837bc6d 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -15477,10 +15477,11 @@ handle_one_xevent (struct x_display_info *dpyinfo, #else f = x_top_window_to_frame (dpyinfo, event->xcrossing.window); #endif -#if defined USE_X_TOOLKIT && defined HAVE_XINPUT2 +#if defined USE_X_TOOLKIT && defined HAVE_XINPUT2 && !defined USE_MOTIF /* The XI2 event mask is set on the frame widget, so this event likely originates from the shell widget, which we aren't - interested in. */ + interested in. (But don't ignore this on Motif, since we + want to clear the mouse face when a popup is active.) */ if (dpyinfo->supports_xi2) f = NULL; #endif -- 2.39.2