summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRenato Ferreira <renatofdds@gmail.com>2019-08-16 11:44:38 -0300
committerKyle Meyer <kyle@kyleam.com>2019-08-16 18:30:09 -0400
commit413736f31580c3b18c4e31f2ca6ee82cff68e70c (patch)
treeacc90e8ab7b85017a7e329de9412f0bc130a0750
parentebf10f126c5218885c49b12b471a9f5501cec9c4 (diff)
downloadorg-mode-413736f31580c3b18c4e31f2ca6ee82cff68e70c.tar.gz
org-todo: Respect state argument when called from elisp
* lisp/org.el (org-todo): Respect argument when called from elisp when calling from elisp (such as in `org-clock-in'). Fast selection should only be shown if a state argument was not used. This fixes a regression introduced by f1c030bed (Prefix argument to `org-todo' forces stage change logging, 2019-08-14). TINYCHANGE
-rw-r--r--lisp/org.el6
1 files changed, 3 insertions, 3 deletions
diff --git a/lisp/org.el b/lisp/org.el
index 2451273..1b91adc 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -10100,9 +10100,6 @@ When called through ELisp, arg is also interpreted in the following way:
(length tail) 2)
org-todo-keywords-1)
(org-last org-todo-keywords-1))))
- ((and org-todo-key-trigger org-use-fast-todo-selection)
- ;; Use fast selection.
- (org-fast-todo-selection this))
(arg
;; User or caller requests a specific state.
(cond
@@ -10121,6 +10118,9 @@ When called through ELisp, arg is also interpreted in the following way:
(user-error "State `%s' not valid in this file" arg))
((nth (1- (prefix-numeric-value arg))
org-todo-keywords-1))))
+ ((and org-todo-key-trigger org-use-fast-todo-selection)
+ ;; Use fast selection.
+ (org-fast-todo-selection this))
((null member) (or head (car org-todo-keywords-1)))
((equal this final-done-word) nil) ;-> make empty
((null tail) nil) ;-> first entry