From c59c2b791d52cbdaacf564e49fa92cf40a60b3f7 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 27 Nov 2009 16:26:11 +0100 Subject: [PATCH] Fix clocking to allow again selection of a task in the history --- lisp/ChangeLog | 3 +++ lisp/org-clock.el | 9 +++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c9def2671..c2c108953 100755 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2009-11-27 Carsten Dominik + * org-clock.el (org-clock-in): Fix current task detection when a + task is selected from the clock history. + * org-latex.el (org-export-latex-class-options): New variable. (org-export-latex-set-initial-vars): Use the class options. diff --git a/lisp/org-clock.el b/lisp/org-clock.el index 16c257712..90a16426d 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -854,8 +854,13 @@ the clocking selection, associated with the letter `d'." (when (save-excursion (org-back-to-heading t) (and (equal (marker-buffer org-clock-hd-marker) - (current-buffer)) - (= (marker-position org-clock-hd-marker) (point)))) + (if selected-task + (marker-buffer selected-task) + (current-buffer))) + (= (marker-position org-clock-hd-marker) + (if selected-task + (marker-position selected-task) + (point))))) (message "Clock continues in \"%s\"" org-clock-heading) (throw 'abort nil)) (move-marker org-clock-interrupted-task