#define FALSE 0
#endif /* no TRUE */
-Lisp_Object Vmenu_updating_frame;
-
Lisp_Object Qdebug_on_next_call;
+extern Lisp_Object Vmenu_updating_frame;
+
extern Lisp_Object Qmenu_bar;
extern Lisp_Object QCtoggle, QCradio;
{
menu_items_inuse = in_use ? Qt : Qnil;
popup_activated_flag = in_use;
+#ifdef USE_X_TOOLKIT
+ if (popup_activated_flag)
+ x_activate_timeout_atimer ();
+#endif
}
/* Wait for an X event to arrive or for a timer to expire. */
}
}
-DEFUN ("menu-bar-start", Fmenu_bar_start, Smenu_bar_start, 0, 1, "i",
+DEFUN ("menu-bar-open", Fmenu_bar_open, Smenu_bar_open, 0, 1, "i",
doc: /* Start key navigation of the menu bar in FRAME.
This initially opens the first menu bar item and you can then navigate with the
arrow keys, select a menu entry with the return key or cancel with the
#ifdef USE_GTK
-DEFUN ("menu-bar-start", Fmenu_bar_start, Smenu_bar_start, 0, 1, "i",
+DEFUN ("menu-bar-open", Fmenu_bar_open, Smenu_bar_open, 0, 1, "i",
doc: /* Start key navigation of the menu bar in FRAME.
This initially opens the first menu bar item and you can then navigate with the
arrow keys, select a menu entry with the return key or cancel with the
XtPointer client_data;
{
popup_activated_flag = 1;
+#ifdef USE_X_TOOLKIT
+ x_activate_timeout_atimer ();
+#endif
}
#endif
/* Display the menu. */
lw_popup_menu (menu, (XEvent *) &dummy);
popup_activated_flag = 1;
+ x_activate_timeout_atimer ();
{
int fact = 4 * sizeof (LWLIB_ID);
/* Display the dialog box. */
lw_pop_up_all_widgets (dialog_id);
popup_activated_flag = 1;
+ x_activate_timeout_atimer ();
/* Process events that apply to the dialog box.
Also handle timers. */
Qdebug_on_next_call = intern ("debug-on-next-call");
staticpro (&Qdebug_on_next_call);
- DEFVAR_LISP ("menu-updating-frame", &Vmenu_updating_frame,
- doc: /* Frame for which we are updating a menu.
-The enable predicate for a menu command should check this variable. */);
- Vmenu_updating_frame = Qnil;
-
#ifdef USE_X_TOOLKIT
widget_id_tick = (1<<16);
next_menubar_widget_id = 1;
defsubr (&Sx_popup_menu);
#if defined (USE_GTK) || defined (USE_X_TOOLKIT)
- defsubr (&Smenu_bar_start);
+ defsubr (&Smenu_bar_open);
+ Ffset (intern ("accelerate-menu"), intern (Smenu_bar_open.symbol_name));
#endif
#ifdef HAVE_MENUS