Browse Source

Require org-clock.el where needed.

Also declare org-notify instead of org-show-notification.

This was reported by Łukasz Stelmach <lukasz.stelmach@iem.pw.edu.pl>
See http://article.gmane.org/gmane.emacs.orgmode/29900
Bastien Guerry 14 years ago
parent
commit
413caacfd7
1 changed files with 2 additions and 1 deletions
  1. 2 1
      lisp/org-timer.el

+ 2 - 1
lisp/org-timer.el

@@ -31,7 +31,7 @@
 
 (require 'org)
 
-(declare-function org-show-notification "org-clock" (parameters))
+(declare-function org-notify "org-clock" (notification &optional play-sound))
 (declare-function org-agenda-error "org-agenda" ())
 
 (defvar org-timer-start-time nil
@@ -374,6 +374,7 @@ replace any running timer."
 		       (y-or-n-p "Replace current timer? ")))
 	      (not org-timer-current-timer))
 	  (progn
+	    (require 'org-clock)
 	    (when org-timer-current-timer
 	      (cancel-timer org-timer-current-timer))
 	    (setq org-timer-current-timer