diff options
| -rw-r--r-- | lisp/ChangeLog | 4 | ||||
| -rw-r--r-- | lisp/emacs-lisp/timer.el | 5 |
2 files changed, 5 insertions, 4 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 93cf3c44033..db19df15619 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2011-07-04 Paul Eggert <eggert@cs.ucla.edu> | ||
| 2 | |||
| 3 | * emacs-lisp/timer.el (timer-until): Use time-subtract and float-time. | ||
| 4 | |||
| 1 | 2011-07-04 Juanma Barranquero <lekktu@gmail.com> | 5 | 2011-07-04 Juanma Barranquero <lekktu@gmail.com> |
| 2 | 6 | ||
| 3 | * type-break.el (timep): Use the value of `float-time' to avoid a | 7 | * type-break.el (timep): Use the value of `float-time' to avoid a |
diff --git a/lisp/emacs-lisp/timer.el b/lisp/emacs-lisp/timer.el index 27fd79a6ad2..e5d21c35100 100644 --- a/lisp/emacs-lisp/timer.el +++ b/lisp/emacs-lisp/timer.el | |||
| @@ -258,10 +258,7 @@ how many will really happen.") | |||
| 258 | "Calculate number of seconds from when TIMER will run, until TIME. | 258 | "Calculate number of seconds from when TIMER will run, until TIME. |
| 259 | TIMER is a timer, and stands for the time when its next repeat is scheduled. | 259 | TIMER is a timer, and stands for the time when its next repeat is scheduled. |
| 260 | TIME is a time-list." | 260 | TIME is a time-list." |
| 261 | ;; FIXME: (float-time (time-subtract (timer--time timer) time)) | 261 | (float-time (time-subtract time (timer--time timer)))) |
| 262 | (let ((high (- (car time) (timer--high-seconds timer))) | ||
| 263 | (low (- (nth 1 time) (timer--low-seconds timer)))) | ||
| 264 | (+ low (* high 65536)))) | ||
| 265 | 262 | ||
| 266 | (defun timer-event-handler (timer) | 263 | (defun timer-event-handler (timer) |
| 267 | "Call the handler for the timer TIMER. | 264 | "Call the handler for the timer TIMER. |