diff options
author | Richard M. Stallman <rms@gnu.org> | 1994-05-14 08:33:26 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 1994-05-14 08:33:26 +0000 |
commit | 7896e49e36b14a529078504439eb938fe8fa7a97 (patch) | |
tree | 5d9042967fa9e87530ac99eb3fdcf62b987ee68c /lisp/ediff.el | |
parent | 0662f28c2072cba5969fc22a947fb0804bf1326a (diff) | |
download | emacs-7896e49e36b14a529078504439eb938fe8fa7a97.tar.gz |
Move menu bar defines to top level
and split them among three top-level sexps.
Diffstat (limited to 'lisp/ediff.el')
-rw-r--r-- | lisp/ediff.el | 70 |
1 files changed, 36 insertions, 34 deletions
diff --git a/lisp/ediff.el b/lisp/ediff.el index 871af29acd4..f7d726d14ee 100644 --- a/lisp/ediff.el +++ b/lisp/ediff.el @@ -1451,63 +1451,65 @@ Do not start with `~/' or `~user-name/'.") (defvar ediff-mode-map nil "Local keymap used in Ediff mode.") -(if (and window-system ediff-want-default-menus (ediff-frame-has-menubar)) - (if (ediff-if-lucid) - (progn ;; Lucid menu bars - (defvar ediff-menu - '("" - ["Between Files ..." ediff-files t] - ["Between Buffers ..." ediff-buffers t] - ["With a Revision via VC ..." vc-ediff t] - ["With a Revision via RCS ..." rcs-ediff t])) - (defvar epatch-menu - '("" - ["To a File ..." ediff-patch-file t] - ["To a Buffer ..." ediff-patch-buffer t])) - (add-menu '("File") "Find Differences" - ediff-menu - "Delete Screen") - (add-menu '("File") "Apply Patch" - epatch-menu - "Delete Screen") - ;; Displays as a solid horizontal line - (add-menu-item '("File") "---" nil nil "Delete Screen") - ) - ;; FSF menu bars +;;; This is split in three parts to avoid +;;; making a line in loaddefs.el that is too long for patch. +;;; Note that autoload.el currently looks for cookies +;;; only at top level in the file. ;;;###autoload +(if (not (ediff-if-lucid)) + (progn (defvar menu-bar-epatch-menu (make-sparse-keymap "menu-bar-epatch-map")) -;;;###autoload (fset 'menu-bar-epatch-menu (symbol-value 'menu-bar-epatch-menu)) -;;;###autoload (defvar menu-bar-ediff-menu (make-sparse-keymap "menu-bar-ediff-map")) -;;;###autoload - (fset 'menu-bar-ediff-menu (symbol-value 'menu-bar-ediff-menu)) + (fset 'menu-bar-ediff-menu (symbol-value 'menu-bar-ediff-menu)))) ;;;###autoload +(if (not (ediff-if-lucid)) + (progn (define-key menu-bar-ediff-menu [rcs-ediff] '("With a Revision via RCS ..." . rcs-ediff)) -;;;###autoload (define-key menu-bar-ediff-menu [vc-ediff] '("With a Revision via VC ..." . vc-ediff)) -;;;###autoload (define-key menu-bar-ediff-menu [ediff-buffers] '("Between Buffers ..." . ediff-buffers)) -;;;###autoload (define-key menu-bar-ediff-menu [ediff-files] - '("Between Files ..." . ediff-files)) + '("Between Files ..." . ediff-files)))) ;;;###autoload +(if (not (ediff-if-lucid)) + (progn (define-key menu-bar-epatch-menu [ediff-patch-buffer] '("To a Buffer ..." . ediff-patch-buffer)) -;;;###autoload (define-key menu-bar-epatch-menu [ediff-patch-file] '("To a File ..." . ediff-patch-file)) (define-key menu-bar-file-menu [epatch] '("Apply Patch" . menu-bar-epatch-menu)) (define-key menu-bar-file-menu [ediff] - '("Find Differences" . menu-bar-ediff-menu)) - )) + '("Find Differences" . menu-bar-ediff-menu)))) + +(if (and window-system ediff-want-default-menus (ediff-frame-has-menubar)) + (if (ediff-if-lucid) + (progn ;; Lucid menu bars + (defvar ediff-menu + '("" + ["Between Files ..." ediff-files t] + ["Between Buffers ..." ediff-buffers t] + ["With a Revision via VC ..." vc-ediff t] + ["With a Revision via RCS ..." rcs-ediff t])) + (defvar epatch-menu + '("" + ["To a File ..." ediff-patch-file t] + ["To a Buffer ..." ediff-patch-buffer t])) + (add-menu '("File") "Find Differences" + ediff-menu + "Delete Screen") + (add-menu '("File") "Apply Patch" + epatch-menu + "Delete Screen") + ;; Displays as a solid horizontal line + (add-menu-item '("File") "---" nil nil "Delete Screen") + ))) (defun ediff-setup-keymap () |