Mercurial > emacs
comparison lisp/vc-bzr.el @ 94003:2ecb2ea8d5b5
Change `dir-status' to not take (and pass) status-buffer.
(vc-status-create-fileinfo): Make `extra' optional.
(vc-status-busy): New fun.
(vc-status-menu-map): Use it.
(vc-status-crt-marked): Remove.
(vc-status-update): Rename from vc-status-add-entries.
Add argument so as to prevent addition of entries. Rewrite.
(vc-update-vc-status-buffer): Remove.
(vc-status-refresh): Don't remove old entries, set them to
up-to-date instead. Also do it after the update is complete.
(vc-status-marked-files): ¦Ç-reduce.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Fri, 11 Apr 2008 15:17:59 +0000 |
parents | c53b75d15c27 |
children | 34110d646fc8 |
comparison
equal
deleted
inserted
replaced
94002:bae1479690d4 | 94003:2ecb2ea8d5b5 |
---|---|
656 'edited)) ")") | 656 'edited)) ")") |
657 ;; else fall back to default vc.el representation | 657 ;; else fall back to default vc.el representation |
658 (vc-default-dired-state-info 'Bzr file))) | 658 (vc-default-dired-state-info 'Bzr file))) |
659 | 659 |
660 ;; XXX: this needs testing, it's probably incomplete. | 660 ;; XXX: this needs testing, it's probably incomplete. |
661 (defun vc-bzr-after-dir-status (update-function status-buffer) | 661 (defun vc-bzr-after-dir-status (update-function) |
662 (let ((status-str nil) | 662 (let ((status-str nil) |
663 (file nil) | 663 (file nil) |
664 (translation '(("+N" . added) | 664 (translation '(("+N" . added) |
665 ("-D" . removed) | 665 ("-D" . removed) |
666 (" M" . edited) | 666 (" M" . edited) |
691 (push (list (buffer-substring-no-properties | 691 (push (list (buffer-substring-no-properties |
692 (+ (point) 4) | 692 (+ (point) 4) |
693 (line-end-position)) | 693 (line-end-position)) |
694 translated) result)) | 694 translated) result)) |
695 (forward-line)) | 695 (forward-line)) |
696 (funcall update-function result status-buffer))) | 696 (funcall update-function result))) |
697 | 697 |
698 ;; XXX Experimental function for the vc-dired replacement. | 698 ;; XXX Experimental function for the vc-dired replacement. |
699 ;; XXX This probably needs some further refinement and testing. | 699 ;; XXX This probably needs some further refinement and testing. |
700 (defun vc-bzr-dir-status (dir update-function status-buffer) | 700 (defun vc-bzr-dir-status (dir update-function) |
701 "Return a list of conses (file . state) for DIR." | 701 "Return a list of conses (file . state) for DIR." |
702 ;; XXX: Is this the right command to use? | 702 ;; XXX: Is this the right command to use? |
703 (vc-bzr-command "status" (current-buffer) 'async dir "-v" "-S") | 703 (vc-bzr-command "status" (current-buffer) 'async dir "-v" "-S") |
704 (vc-exec-after | 704 (vc-exec-after |
705 `(vc-bzr-after-dir-status (quote ,update-function) ,status-buffer))) | 705 `(vc-bzr-after-dir-status (quote ,update-function)))) |
706 | 706 |
707 ;;; Revision completion | 707 ;;; Revision completion |
708 | 708 |
709 (defun vc-bzr-complete-with-prefix (prefix action table string pred) | 709 (defun vc-bzr-complete-with-prefix (prefix action table string pred) |
710 (let ((comp (complete-with-action action table string pred))) | 710 (let ((comp (complete-with-action action table string pred))) |