From dcf64c7ee338d4e50a95427848bc8650184cd9de Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Tue, 2 Dec 2014 11:47:18 +0100 Subject: [PATCH] org-timer: Fix `org-timer-stop' * lisp/org-timer.el (org-timer-stop): Do not modify `org-timer-current-timer', which is related to countdown timer, a different feature. --- lisp/org-timer.el | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lisp/org-timer.el b/lisp/org-timer.el index bcc3e1c0c..d02362cc2 100644 --- a/lisp/org-timer.el +++ b/lisp/org-timer.el @@ -156,14 +156,12 @@ With prefix arg STOP, stop it entirely." (org-timer-set-mode-line 'pause) (message "Timer paused at %s" (org-timer-value-string))))) -(defvar org-timer-current-timer nil) (defun org-timer-stop () "Stop the relative timer." (interactive) (run-hooks 'org-timer-stop-hook) (setq org-timer-start-time nil - org-timer-pause-time nil - org-timer-current-timer nil) + org-timer-pause-time nil) (org-timer-set-mode-line 'off) (message "Timer stopped")) @@ -349,6 +347,7 @@ VALUE can be `on', `off', or `pause'." (concat " <" (substring (org-timer-value-string) 0 -1) ">")) (force-mode-line-update))) +(defvar org-timer-current-timer nil) (defun org-timer-cancel-timer () "Cancel the current timer." (interactive)