diff options
Diffstat (limited to 'lisp/calendar/timeclock.el')
-rw-r--r-- | lisp/calendar/timeclock.el | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/lisp/calendar/timeclock.el b/lisp/calendar/timeclock.el index ddc0cbe8539..f389e1ccab3 100644 --- a/lisp/calendar/timeclock.el +++ b/lisp/calendar/timeclock.el @@ -543,11 +543,8 @@ non-nil, the amount returned will be relative to past time worked." (message "%s" string) string))) -(defsubst timeclock-time-to-seconds (time) - "Convert TIME to a floating point number." - (+ (* (car time) 65536.0) - (cadr time) - (/ (or (nth 2 time) 0) 1000000.0))) +(defalias 'timeclock-time-to-seconds (if (fboundp 'float-time) 'float-time + 'time-to-seconds)) (defsubst timeclock-seconds-to-time (seconds) "Convert SECONDS (a floating point number) to an Emacs time structure." @@ -1419,5 +1416,4 @@ HTML-P is non-nil, HTML markup is added." (if (file-readable-p timeclock-file) (timeclock-reread-log)) -;; arch-tag: a0be3377-deb6-44ec-b9a2-a7be28436a40 ;;; timeclock.el ends here |