return Qnil;
}
+static void
+clean_up_dialog (void)
+{
+ pgtk_menu_set_in_use (false);
+}
+
DEFUN ("x-file-dialog", Fx_file_dialog, Sx_file_dialog, 2, 5, 0,
doc: /* Read file name, prompting with PROMPT in directory DIR.
Use a file selection dialog. Select DEFAULT-FILENAME in the dialog's file
check_window_system (f);
+ if (popup_activated ())
+ error ("Trying to use a menu from within a menu-entry");
+ else
+ pgtk_menu_set_in_use (true);
+
CHECK_STRING (prompt);
CHECK_STRING (dir);
/* Prevent redisplay. */
specbind (Qinhibit_redisplay, Qt);
-#if 0
record_unwind_protect_void (clean_up_dialog);
-#endif
block_input ();
/* Wait for an X event to arrive or for a timer to expire. */
-void
+static void
pgtk_menu_wait_for_event (void *data)
{
struct timespec next_time = timer_check (), *ntp;
extern void pgtk_default_font_parameter (struct frame *f, Lisp_Object parms);
+extern void pgtk_menu_set_in_use (bool in_use);
+
+
extern void pgtk_enqueue_string(struct frame *f, gchar *str);
extern void pgtk_enqueue_preedit(struct frame *f, Lisp_Object image_data);
extern void pgtk_im_focus_in(struct frame *f);