From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stephan Schmitt Subject: [PATCH 2/2] set variables org-timer-timer[123] correctly Date: Thu, 5 Nov 2009 10:57:35 +0100 Message-ID: <1257415055-8120-2-git-send-email-drmabuse@cs.tu-berlin.de> References: <1257415055-8120-1-git-send-email-drmabuse@cs.tu-berlin.de> Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1N5z7A-0000Tp-A2 for emacs-orgmode@gnu.org; Thu, 05 Nov 2009 04:58:48 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1N5z75-0000SN-Ok for emacs-orgmode@gnu.org; Thu, 05 Nov 2009 04:58:47 -0500 Received: from [199.232.76.173] (port=42711 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1N5z75-0000SK-I0 for emacs-orgmode@gnu.org; Thu, 05 Nov 2009 04:58:43 -0500 Received: from algieba.ni.cs.tu-berlin.de ([130.149.24.75]:53022) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1N5z75-0003Jv-2k for emacs-orgmode@gnu.org; Thu, 05 Nov 2009 04:58:43 -0500 In-Reply-To: <1257415055-8120-1-git-send-email-drmabuse@cs.tu-berlin.de> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org before these variables were set to nil, and consequently org-timer-last-timer as well. --- lisp/org-timer.el | 12 ++++++------ 1 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lisp/org-timer.el b/lisp/org-timer.el index 8a59c74..660312a 100644 --- a/lisp/org-timer.el +++ b/lisp/org-timer.el @@ -312,12 +312,12 @@ VALUE can be `on', `off', or `pause'." (t (error "Not in an Org buffer")))) timer-set) (mapcar (lambda(timer) - (if (not (or (eval timer) timer-set)) - (setq timer-set t - timer - (run-with-timer - secs nil 'org-notify (format "%s: time out" hl) t) - org-timer-last-timer timer))) + (when (not (or (eval timer) timer-set)) + (setq timer-set t) + (setq org-timer-last-timer + (run-with-timer + secs nil 'org-notify (format "%s: time out" hl) t)) + (set timer org-timer-last-timer))) '(org-timer-timer1 org-timer-timer2 org-timer-timer3))))) -- 1.6.4.4