GNU bug report logs - #67993
Selecting buffer automatically

Previous Next

Package: emacs;

Reported by: Juri Linkov <juri <at> linkov.net>

Date: Sat, 23 Dec 2023 17:56:01 UTC

Severity: wishlist

Tags: patch

Fixed in version 30.0.50

Done: Juri Linkov <juri <at> linkov.net>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: martin rudalics <rudalics <at> gmx.at>
To: Juri Linkov <juri <at> linkov.net>, 67993 <at> debbugs.gnu.org
Subject: bug#67993: Selecting buffer automatically
Date: Fri, 5 Jan 2024 10:23:10 +0100
> Martin, do you agree with this change?
> If ok, then I could update the documentation as well.

The following looks like a glitch:

>> +                      (when (window-live-p (old-selected-window))
>> +                        (select-window (old-selected-window))))

is supposed to select the window selected the last time we ran window
change functions.  Now consider the following scenario:

- Redisplay runs the window change functions and sets the old selected
  window.

- An application changes the selected window.

- 'display-buffer' gets called with a (select-window . nil) entry.  The
  call will select the window selected at last redisplay.

So I think that calling 'old-selected-window' here is not TRT.

martin




This bug report was last modified 1 year and 124 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.