diff options
author | Myles English <mylesenglish@gmail.com> | 2012-10-26 12:38:09 +0100 |
---|---|---|
committer | Bastien Guerry <bzg@altern.org> | 2012-10-26 14:47:23 +0200 |
commit | db8e06147ae0f30f2507453a91b3ac3fcb43c79f (patch) | |
tree | 1c68cf88be6b8a834f95e5fb7aad0f9ed7dfaf09 | |
parent | 58551f1e5f3747fd82c8a061c8129476f48ad296 (diff) | |
download | org-mode-db8e06147ae0f30f2507453a91b3ac3fcb43c79f.tar.gz |
Clocking: Move to task before calling org-clock-in-prepare-hook
* lisp/org-clock.el (org-clock-in): Moved the call to
org-clock-in-prepare-hook until the task's properties
can be accessed.
The problem was when using a function to add an effort
property via the hook, it would not recognise an existing
effort property when called with the prefix (C-u C-c C-x C-i)
with the point at a place other than at the task.
TINYCHANGE
-rw-r--r-- | lisp/org-clock.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lisp/org-clock.el b/lisp/org-clock.el index fd95bc0..3f252fd 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -1138,7 +1138,6 @@ make this the default behavior.)" (if (and (eobp) (not (org-at-heading-p))) (point-at-bol 0) (point))) - (run-hooks 'org-clock-in-prepare-hook) (save-excursion (when (and selected-task (marker-buffer selected-task)) ;; There is a selected task, move to the correct buffer @@ -1157,6 +1156,7 @@ make this the default behavior.)" ;; beginning of the heading, since the ;; user is liking to insert stuff here ;; manually + (run-hooks 'org-clock-in-prepare-hook) (org-clock-history-push)) (org-clock-set-current) (cond ((functionp org-clock-in-switch-to-state) |