emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

master 9c2b1d37e7: Ensure correct toggle menu item display


From: Gerd Moellmann
Subject: master 9c2b1d37e7: Ensure correct toggle menu item display
Date: Wed, 29 Jun 2022 01:57:04 -0400 (EDT)

branch: master
commit 9c2b1d37e729f7af9e9661be7ece8348bae70ffa
Author: Gerd Möllmann <gerd@gnu.org>
Commit: Gerd Möllmann <gerd@gnu.org>

    Ensure correct toggle menu item display
    
    * lisp/menu-bar.el (menu-bar-make-toggle-command): Call
    force-mode-line-update. (Bug#56155)
---
 lisp/menu-bar.el | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/lisp/menu-bar.el b/lisp/menu-bar.el
index 4a943d2528..92989fcfb2 100644
--- a/lisp/menu-bar.el
+++ b/lisp/menu-bar.el
@@ -749,7 +749,11 @@ by \"Save Options\" in Custom buffers.")
        ;; interactively, because the purpose is to mark the variable as a
        ;; candidate for `Save Options', and we do not want to save options that
        ;; the user has already set explicitly in the init file.
-       (when interactively (customize-mark-as-set ',variable)))
+       (when interactively
+         (customize-mark-as-set ',variable))
+       ;; Toggle menu items must make sure that the menu is updated so
+       ;; that toggle marks are drawn in the right state.
+       (force-mode-line-update t))
      '(menu-item ,item-name ,command :help ,help
                  :button (:toggle . (and (default-boundp ',variable)
                                          (default-value ',variable)))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]