From: Juri Linkov Date: Fri, 25 Jun 2021 09:38:27 +0000 (+0300) Subject: * lisp/tab-bar.el (tab-bar--define-keys): Fix global-mode-string (bug#49215) X-Git-Tag: emacs-28.0.90~2034 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=8b49e99504f7ba30abc90a31b02e2e230e818b75;p=emacs.git * lisp/tab-bar.el (tab-bar--define-keys): Fix global-mode-string (bug#49215) --- diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index f3c2fb7ed96..41d565abd58 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -138,15 +138,12 @@ Possible modifier keys are `control', `meta', `shift', `hyper', `super' and (when (and (memq 'tab-bar-format-global tab-bar-format) (member '(global-mode-string ("" global-mode-string " ")) mode-line-misc-info)) - (setq mode-line-misc-info - (append '(global-mode-string - ("" (:eval (if (and tab-bar-mode - (memq 'tab-bar-format-global - tab-bar-format)) - "" global-mode-string)) - " ")) - (remove '(global-mode-string ("" global-mode-string " ")) - mode-line-misc-info))))) + (setf (alist-get 'global-mode-string mode-line-misc-info) + '(("" (:eval (if (and tab-bar-mode + (memq 'tab-bar-format-global + tab-bar-format)) + "" global-mode-string)) + " "))))) (defun tab-bar--undefine-keys () "Uninstall key bindings previously bound by `tab-bar--define-keys'."