~ubuntu-branches/ubuntu/karmic/emacs-snapshot/karmic

« back to all changes in this revision

Viewing changes to src/xmenu.c

  • Committer: Bazaar Package Importer
  • Author(s): Reinhard Tartler
  • Date: 2009-04-05 09:14:30 UTC
  • mto: This revision was merged to the branch mainline in revision 34.
  • Revision ID: james.westby@ubuntu.com-20090405091430-nw07lynn2arotjbe
Tags: upstream-20090320
ImportĀ upstreamĀ versionĀ 20090320

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/* X Communication module for terminals which understand the X protocol.
2
2
   Copyright (C) 1986, 1988, 1993, 1994, 1996, 1999, 2000, 2001, 2002, 2003,
3
 
                 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
3
                 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc.
4
4
 
5
5
This file is part of GNU Emacs.
6
6
 
604
604
  if (! FRAME_X_P (f) && ! FRAME_MSDOS_P (f))
605
605
    error ("Can not put X dialog on this terminal");
606
606
 
 
607
  /* Force a redisplay before showing the dialog.  If a frame is created
 
608
     just before showing the dialog, its contents may not have been fully
 
609
     drawn, as this depends on timing of events from the X server.  Redisplay
 
610
     is not done when a dialog is shown.  If redisplay could be done in the
 
611
     X event loop (i.e. the X event loop does not run in a signal handler)
 
612
     this would not be needed.
 
613
 
 
614
     Do this before creating the widget value that points to Lisp
 
615
     string contents, because Fredisplay may GC and relocate them.  */
 
616
  Fredisplay (Qt);
 
617
 
607
618
#if ! defined (USE_X_TOOLKIT) && ! defined (USE_GTK)
608
619
  /* Display a menu with these alternatives
609
620
     in the middle of frame F.  */
2448
2459
  /* No selection has been chosen yet.  */
2449
2460
  menu_item_selection = 0;
2450
2461
 
2451
 
  /* Force a redisplay before showing the dialog.  If a frame is created
2452
 
     just before showing the dialog, its contents may not have been fully
2453
 
     drawn, as this depends on timing of events from the X server.  Redisplay
2454
 
     is not done when a dialog is shown.  If redisplay could be done in the
2455
 
     X event loop (i.e. the X event loop does not run in a signal handler)
2456
 
     this would not be needed.  */
2457
 
  Fredisplay (Qt);
2458
 
 
2459
2462
  /* Actually create and show the dialog.  */
2460
2463
  create_and_show_dialog (f, first_wv);
2461
2464