diff options
author | Carsten Dominik <carsten.dominik@gmail.com> | 2009-04-22 06:41:15 +0200 |
---|---|---|
committer | Carsten Dominik <carsten.dominik@gmail.com> | 2009-04-22 06:41:15 +0200 |
commit | 38b5a9e704efdd3a97dd5c182ff54b0043b83515 (patch) | |
tree | 0f436f53e5937a5e5ea9f61187cca2adc0c71cba | |
parent | ec773949d138265fbc496e620340141d557f68a0 (diff) | |
download | org-mode-38b5a9e704efdd3a97dd5c182ff54b0043b83515.tar.gz |
Clock: New variable to allow finding a recent task with `org-clock-goto'
-rwxr-xr-x | lisp/ChangeLog | 4 | ||||
-rw-r--r-- | lisp/org-clock.el | 8 |
2 files changed, 11 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3e4e7c5..8d77dae 100755 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2009-04-22 Carsten Dominik <carsten.dominik@gmail.com> + * org-clock.el (org-clock-goto-may-find-recent-task): New option. + (org-clock-goto): Find recent task only if + `org-clock-goto-may-find-recent-task' allows it. + * org-exp.el (org-export-remove-or-extract-drawers): Handle empty drawers, and drawers that are missing the :END: line. diff --git a/lisp/org-clock.el b/lisp/org-clock.el index 5cd9035..5fd84a6 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -91,6 +91,11 @@ state to switch it to." :group 'org-clock :type 'integer) +(defcustom org-clock-goto-may-find-recent-task t + "Non-nil means, `org-clock-goto' can go to recent task if no active clock." + :group 'org-clock + :type 'boolean) + (defcustom org-clock-heading-function nil "When non-nil, should be a function to create `org-clock-heading'. This is the string shown in the mode line when a clock is running. @@ -538,7 +543,8 @@ With prefix arg SELECT, offer recently clocked tasks for selection." (or (org-clock-select-task "Select task to go to: ") (error "No task selected"))) ((marker-buffer org-clock-marker) org-clock-marker) - ((and (car org-clock-history) + ((and org-clock-goto-may-find-recent-task + (car org-clock-history) (marker-buffer (car org-clock-history))) (setq recent t) (car org-clock-history)) |