diff options
author | Bastien Guerry <bzg@altern.org> | 2014-03-19 16:13:33 +0100 |
---|---|---|
committer | Bastien Guerry <bzg@altern.org> | 2014-03-19 16:13:33 +0100 |
commit | 49da67d351b55c9325e2f587928d28631aa2755d (patch) | |
tree | d59fb4a4fa31e47fbff5478ab827a983c3be51dc | |
parent | 3a233aa6d94f27d4c4c11fb7a679a47b97001a2c (diff) | |
download | org-mode-49da67d351b55c9325e2f587928d28631aa2755d.tar.gz |
org.el (org-refile): Fix C-u 3 C-c C-w
* org.el (org-refile): Fix calling with a numeric prefix
argument of 3 to refile and keep.
-rw-r--r-- | lisp/org.el | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/lisp/org.el b/lisp/org.el index 25926b7..6c0f04e 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -11520,7 +11520,9 @@ prefix argument (`C-u C-u C-u C-c C-w')." (interactive "P") (if (member goto '(0 (64))) (org-refile-cache-clear) - (let* ((actionmsg (or msg "Refile")) + (let* ((actionmsg (cond (msg msg) + ((equal goto 3) "Refile (and keep)") + (t "Refile"))) (cbuf (current-buffer)) (regionp (org-region-active-p)) (region-start (and regionp (region-beginning))) @@ -11555,13 +11557,13 @@ prefix argument (`C-u C-u C-u C-c C-w')." (setq it (or rfloc (let (heading-text) (save-excursion - (unless goto + (unless (and goto (listp goto)) (org-back-to-heading t) (setq heading-text (nth 4 (org-heading-components)))) (org-refile-get-location - (cond (goto "Goto") + (cond ((and goto (listp goto)) "Goto") (regionp (concat actionmsg " region to")) (t (concat actionmsg " subtree \"" heading-text "\" to"))) |