org-macs.el (org-with-remote-undo): Normalize argument names

* org-macs.el (org-with-remote-undo): Normalize argument names.
This commit is contained in:
Bastien Guerry 2013-04-10 14:32:55 +02:00
parent 08a47b0959
commit 8e2c29fd38
1 changed files with 4 additions and 5 deletions

View File

@ -162,18 +162,17 @@ We use a macro so that the test can happen at compilation time."
(cons (if (fboundp 'with-no-warnings) 'with-no-warnings 'progn) body))
(def-edebug-spec org-no-warnings (body))
;; FIXME: Normalize argument names
(defmacro org-with-remote-undo (_buffer &rest _body)
(defmacro org-with-remote-undo (buffer &rest body)
"Execute BODY while recording undo information in two buffers."
(org-with-gensyms (cline cmd buf1 buf2 undo1 undo2 c1 c2)
`(let ((,cline (org-current-line))
(,cmd this-command)
(,buf1 (current-buffer))
(,buf2 ,_buffer)
(,buf2 ,buffer)
(,undo1 buffer-undo-list)
(,undo2 (with-current-buffer ,_buffer buffer-undo-list))
(,undo2 (with-current-buffer ,buffer buffer-undo-list))
,c1 ,c2)
,@_body
,@body
(when org-agenda-allow-remote-undo
(setq ,c1 (org-verify-change-for-undo
,undo1 (with-current-buffer ,buf1 buffer-undo-list))