emacs-devel
[Top][All Lists]
Advanced

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

Re: Canceling dialogues


From: Eli Zaretskii
Subject: Re: Canceling dialogues
Date: Mon, 31 Jul 2006 22:57:32 +0300

> Date: Mon, 31 Jul 2006 21:36:19 +0200
> From: Lennart Borgman <address@hidden>
> CC:  address@hidden
> 
> Eli Zaretskii wrote:
> >   
> >> I think this is a bug and that a third alternative for canceling should 
> >> be added.
> >>     
> >
> > The menu only has YES and NO, so that's what is displayed.
> >
> >   
> Yes ... - I was suggesting that we should add a Cancel alternative. So I 
> do not understand what you mean. Can you explain?

When Emacs wants to pop the YES/NO dialog, it calls the function
x-popup-dialog (Fx_popup_dialog), which in the Windows port currently
creates a menu instead of a dialog and pops that menu.  This function
(x-popup-dialog) is a general-purpose function, it doesn't know, nor
care, what it gets as the contents of the dialog.  It isn't called
only for the YES/NO type of dialog, you can have other dialogs with
arbitrary long lists of alternatives.

So, unless we somehow program the function to discover that it is
called for YES/NO dialog, we cannot blithely add a CANCEL button to
it.

If you meant to add code to x-popup-dialog that would recognize this
special case, I think fixing the generic dialog code is a better
investment of our resources and energy, and the result is going to be
much cleaner.

In addition, there's the question what to do for CANCEL, as someone
else pointed out.




reply via email to

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