changeset 8169:09a8da4ffadf

(make_lispy_event): Ignore menu bar up events.
author Richard M. Stallman <rms@gnu.org>
date Thu, 07 Jul 1994 06:42:21 +0000
parents 32fbb27091d4
children d92a24366b22
files src/keyboard.c
diffstat 1 files changed, 8 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/keyboard.c	Thu Jul 07 06:38:42 1994 +0000
+++ b/src/keyboard.c	Thu Jul 07 06:42:21 1994 +0000
@@ -2608,6 +2608,14 @@
 #endif
 	      {
 		Lisp_Object items, item;
+		int hpos;
+		int i;
+
+		/* Activate the menu bar on the down event.  If the
+		   up event comes in before the menu code can deal with it,
+		   just ignore it.  */
+		if (! (event->modifiers & down_modifier))
+		  return Qnil;
 
 #ifdef USE_X_TOOLKIT
 		/* The click happened in the menubar.
@@ -2616,9 +2624,6 @@
 
 		XFASTINT (event->y) = 1;
 #else /* not USE_X_TOOLKIT  */
-		int hpos;
-		int i;
-
 		item = Qnil;
 		items = FRAME_MENU_BAR_ITEMS (f);
 		for (i = 0; i < XVECTOR (items)->size; i += 3)