changeset 82500:029c5ed25e99

(vc-menu-map): Don't setup any more. Instead, just create the proper spot in the menu.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Tue, 21 Aug 2007 15:08:47 +0000
parents 3ecf9562ce0b
children 5c15d3c510b1
files lisp/ChangeLog lisp/menu-bar.el
diffstat 2 files changed, 4 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Tue Aug 21 15:07:36 2007 +0000
+++ b/lisp/ChangeLog	Tue Aug 21 15:08:47 2007 +0000
@@ -6,6 +6,9 @@
 	(vc-menu-map): Declare and initialize in one step.
 	(vc-menu-map-filter): Move&rename from menu-bar.el:menu-bar-vc-filter
 
+	* menu-bar.el (vc-menu-map): Don't setup any more.
+	Instead, just create the proper spot in the menu.
+
 2007-08-20  Stefan Monnier  <monnier@iro.umontreal.ca>
 
 	* smerge-mode.el (smerge-resolve): New arg `safe'.
--- a/lisp/menu-bar.el	Tue Aug 21 15:07:36 2007 +0000
+++ b/lisp/menu-bar.el	Tue Aug 21 15:08:47 2007 +0000
@@ -1160,24 +1160,9 @@
 (define-key menu-bar-tools-menu [separator-vc]
   '("--"))
 
-(defvar vc-menu-map (make-sparse-keymap "Version Control"))
-(defalias 'vc-menu-map vc-menu-map)
 (define-key menu-bar-tools-menu [pcl-cvs]
   '(menu-item "PCL-CVS" cvs-global-menu))
-(define-key menu-bar-tools-menu [vc]
-  (list 'menu-item "Version Control" vc-menu-map
-  :filter 'menu-bar-vc-filter))
-
-(defun menu-bar-vc-filter (orig-binding)
-  (let ((ext-binding
-   (if vc-mode (vc-call-backend (vc-backend buffer-file-name) 'extra-menu))))
-    ;; Give the VC backend a chance to add menu entries
-    ;; specific for that backend.
-    (if (null ext-binding)
-    orig-binding
-      (append orig-binding
-	      '((ext-menu-separator "---"))
-	            ext-binding))))
+(define-key menu-bar-tools-menu [vc] nil) ;Create the place for the VC menu.
 
 (define-key menu-bar-tools-menu [separator-compare]
   '("--"))