From: Kyle Meyer <kyle@kyleam.com>
To: Renato Ferreira <renatofdds@gmail.com>,
emacs-orgmode <emacs-orgmode@gnu.org>
Subject: Re: [PATCH] org.el (org-todo): Respect state argument when called from elisp
Date: Fri, 16 Aug 2019 18:41:07 -0400 [thread overview]
Message-ID: <87ef1k4tto.fsf@kyleam.com> (raw)
In-Reply-To: <87imqxywno.fsf@gmail.com>
Renato Ferreira <renatofdds@gmail.com> writes:
> (org-todo): Fast selection should only be shown if a state argument was not used
> * list/org.el (org-todo): Respect argument when called from elisp
> when calling from elisp (such as in `org-clock-in').
Thanks for the patch! I hit this earlier today but hadn't yet looked
into it. Testing this out, it fixes the issue introduced by f1c030bed
(Prefix argument to `org-todo' forces stage change logging, 2019-08-14),
while keeping the intended C-u behavior change from that patch.
> @@ -10121,7 +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
This patch didn't apply for me, and the hunk counts look off. It should
be -10121,6, no? Anyway, I've adjusted it so that it applies and pushed
it to master. (I made a typo fix and a few small tweaks to your commit
message.)
--
Kyle
prev parent reply other threads:[~2019-08-16 22:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-16 14:44 [PATCH] org.el (org-todo): Respect state argument when called from elisp Renato Ferreira
2019-08-16 22:41 ` Kyle Meyer [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87ef1k4tto.fsf@kyleam.com \
--to=kyle@kyleam.com \
--cc=emacs-orgmode@gnu.org \
--cc=renatofdds@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).