comparison lisp/vc-arch.el @ 78822:1926a08e8926

* vc-arch.el (vc-arch-extra-menu-map): New var and fun. * vc-hooks.el (vc-menu-entry): New var. (vc-mode-line-map): Use it so that this menu also uses the extra-menu. (menu-bar-tools-menu): Add the VC menu here rather than in menu-bar.el. (vc-menu-map): Declare and initialize in one step. * menu-bar.el (vc-menu-map): Don't setup any more. Instead, just create the proper spot in the menu. * vc.el: Document new VC operation `extra-menu'. * vc-hooks.el (vc-default-extra-menu, vc-menu-map-filter): New function.
author Dan Nicolaescu <dann@ics.uci.edu>
date Tue, 18 Sep 2007 01:28:25 +0000
parents 2dd5d799a16d
children 73661ddc7ac7
comparison
equal deleted inserted replaced
78821:4341c4b4d652 78822:1926a08e8926
442 ;; FIXME: complete revision patches as well. 442 ;; FIXME: complete revision patches as well.
443 (let* ((root (expand-file-name "{arch}" (vc-arch-root file))) 443 (let* ((root (expand-file-name "{arch}" (vc-arch-root file)))
444 (table (vc-arch--version-completion-table root string))) 444 (table (vc-arch--version-completion-table root string)))
445 (complete-with-action action table string pred))))) 445 (complete-with-action action table string pred)))))
446 446
447 (defvar vc-arch-extra-menu-map
448 (let ((map (make-sparse-keymap)))
449 (define-key map [add-tagline]
450 '(menu-item "Add tagline" vc-arch-add-tagline))
451 map))
452
453 (defun vc-arch-extra-menu () vc-arch-extra-menu-map)
454
455
447 ;;; Less obvious implementations. 456 ;;; Less obvious implementations.
448 457
449 (defun vc-arch-find-version (file rev buffer) 458 (defun vc-arch-find-version (file rev buffer)
450 (let ((out (make-temp-file "vc-out"))) 459 (let ((out (make-temp-file "vc-out")))
451 (unwind-protect 460 (unwind-protect