From 4766fe1daf9f1b3f711d3fe453840487601cce81 Mon Sep 17 00:00:00 2001 From: Juri Linkov Date: Mon, 23 May 2022 10:48:15 +0300 Subject: [PATCH] * lisp/tab-bar.el (switch-to-buffer-other-tab): Use pop-to-buffer (bug#55582). Replace display-buffer with pop-to-buffer that sets the current buffer explicitly. --- lisp/tab-bar.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index 42c4b822bc6..ddab71c52c4 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -2320,9 +2320,9 @@ Interactively, prompt for the buffer to switch to." (declare (advertised-calling-convention (buffer-or-name) "28.1")) (interactive (list (read-buffer-to-switch "Switch to buffer in other tab: "))) - (display-buffer (window-normalize-buffer-to-switch-to buffer-or-name) - '((display-buffer-in-tab) - (inhibit-same-window . nil)))) + (pop-to-buffer (window-normalize-buffer-to-switch-to buffer-or-name) + '((display-buffer-in-tab) + (inhibit-same-window . nil)))) (defun find-file-other-tab (filename &optional wildcards) "Edit file FILENAME, in another tab. -- 2.39.2