summaryrefslogtreecommitdiff
path: root/lisp/menu-bar.el
diff options
context:
space:
mode:
authorStefan Monnier <monnier@iro.umontreal.ca>2005-03-22 19:44:38 +0000
committerStefan Monnier <monnier@iro.umontreal.ca>2005-03-22 19:44:38 +0000
commit4a4a82d641ebf61e53f6e0d211f27456d0f38d00 (patch)
tree78062389a1d804d30737ca16a1fe3eb343dd9013 /lisp/menu-bar.el
parent44ebeb1b6ea04630f98f18c296ae098fc400dcbd (diff)
downloademacs-4a4a82d641ebf61e53f6e0d211f27456d0f38d00.tar.gz
(showhide-date-time): Remove.
(menu-bar-showhide-menu): Use menu-bar-make-mm-toggle. (menu-bar-make-mm-toggle): Simplify.
Diffstat (limited to 'lisp/menu-bar.el')
-rw-r--r--lisp/menu-bar.el19
1 files changed, 6 insertions, 13 deletions
diff --git a/lisp/menu-bar.el b/lisp/menu-bar.el
index 8dfb6a792df..d988cae1260 100644
--- a/lisp/menu-bar.el
+++ b/lisp/menu-bar.el
@@ -1,6 +1,7 @@
;;; menu-bar.el --- define a default menu bar
-;; Copyright (C) 1993,94,1995,2000,01,02,2003 Free Software Foundation, Inc.
+;; Copyright (C) 1993, 1994, 1995, 2000, 2001, 2002, 2003, 2005
+;; Free Software Foundation, Inc.
;; Author: RMS
;; Maintainer: FSF
@@ -596,7 +597,7 @@ DOC is the text to use for the menu entry.
HELP is the text to use for the tooltip.
PROPS are additional properties."
`'(menu-item ,doc ,fname
- ,@(if props props)
+ ,@props
:help ,help
:button (:toggle . (and (default-boundp ',fname)
(default-value ',fname)))))
@@ -693,18 +694,10 @@ by \"Save Options\" in Custom buffers.")
(define-key menu-bar-showhide-menu [linecolumn-separator]
'("--"))
-(defun showhide-date-time ()
- "Toggle whether to show date and time in the mode-line."
- (interactive)
- (if (display-time-mode)
- (message "Display-time mode enabled.")
- (message "Display-time mode disabled."))
- (customize-mark-as-set 'display-time-mode))
-
(define-key menu-bar-showhide-menu [showhide-date-time]
- '(menu-item "Date, Time and Mail" showhide-date-time
- :help "Display date, time, mail status in mode line"
- :button (:toggle . display-time-mode)))
+ (menu-bar-make-mm-toggle display-time-mode
+ "Date, Time and Mail"
+ "Display date, time, mail status in mode line"))
(define-key menu-bar-showhide-menu [datetime-separator]
'("--"))