emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master a61cc138ede: Prevent errors when generating events above menu bar


From: Po Lu
Subject: master a61cc138ede: Prevent errors when generating events above menu bar windows
Date: Tue, 31 Oct 2023 23:15:59 -0400 (EDT)

branch: master
commit a61cc138edeee269e8cf62c13058d5258310d7bc
Author: Po Lu <luangruo@yahoo.com>
Commit: Po Lu <luangruo@yahoo.com>

    Prevent errors when generating events above menu bar windows
    
    * src/keyboard.c (make_lispy_position): Pass false to w_f_c,
    for the subsequent code is not prepared to encounter menu bar
    windows.
---
 src/keyboard.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/keyboard.c b/src/keyboard.c
index c00f48d7836..003340c3e58 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -5561,9 +5561,10 @@ make_lispy_position (struct frame *f, Lisp_Object x, 
Lisp_Object y,
   /* Coordinate pixel positions to return.  */
   int xret = 0, yret = 0;
   /* The window or frame under frame pixel coordinates (x,y)  */
-  Lisp_Object window_or_frame = f
-    ? window_from_coordinates (f, mx, my, &part, true, true, true)
-    : Qnil;
+  Lisp_Object window_or_frame = (f != NULL
+                                ? window_from_coordinates (f, mx, my, &part,
+                                                           false, true, true)
+                                : Qnil);
 #ifdef HAVE_WINDOW_SYSTEM
   bool tool_bar_p = false;
   bool menu_bar_p = false;



reply via email to

[Prev in Thread] Current Thread [Next in Thread]