Subject: bug#56305: 29.0.50; 'yes-or-no-p' deselects minibuffer frame

From: Alan Mackenzie <[email-masked]>
Date: Wed, 6 Jul 2022 19:22:29 +0000

Hello, Andreas.

On Wed, Jul 06, 2022 at 21:09:32 +0200, Andreas Schwab wrote:
> On Jul 06 2022, Alan Mackenzie wrote:

> > Not obviously.  We're about to run the recursive edit for read_minibuf,
> > so the frame with the mini-window should have the focus anyway.

> Does it?  I don't see why Emacs must be in the foreground when it wants
> to read from the minibuffer.

Ah right - a different program might have the focus, and a user typing
into that other program would suddenly find herself typing into the
Emacs minibuffer instead.  This isn't ideal.

Maybe there's some way of testing whether some Emacs frame has the focus
before executing Fx_focus_frame, and if not, not executing
Fx_focus_frame.

> -- 
> Andreas Schwab, [email-masked]
> GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
> "And now for something completely different."

-- 
Alan Mackenzie (Nuremberg, Germany).