Fix setting dedicatedness of WINDOW in 'window--display-buffer' (Bug#76911)

* lisp/window.el (window--display-buffer): Consult WINDOW's
'window-side' parameter in order to find out whether it is a
side window (Bug#76911).
This commit is contained in:
Martin Rudalics 2025-03-10 18:42:00 +01:00
parent 7a72589847
commit fd4de89460

View file

@ -7690,7 +7690,8 @@ Return WINDOW if BUFFER and WINDOW are live."
;; Don't dedicate WINDOW if it is dedicated because it shows
;; BUFFER already or it is reused and is not a side window.
((or (window-dedicated-p window)
(and (eq type 'reuse) (not (eq (cdr alist-dedicated) 'side)))))
(and (eq type 'reuse)
(not (window-parameter window 'window-side)))))
;; Otherwise, if ALIST contains a 'dedicated' entry, use that
;; entry's value (which may be nil).
(alist-dedicated