diff options
author | Bastien Guerry <bzg@altern.org> | 2013-04-09 16:15:17 +0200 |
---|---|---|
committer | Bastien Guerry <bzg@altern.org> | 2013-04-09 16:15:17 +0200 |
commit | 872e3736d7f9582288e7a53690972d5e1c0cac31 (patch) | |
tree | d5af9a2be51849f20e97fc429beaf754e239caed | |
parent | 33f800ccd2eb931a8133ceb821ac89c432992375 (diff) | |
download | org-mode-872e3736d7f9582288e7a53690972d5e1c0cac31.tar.gz |
org.el (org-minutes-to-clocksum-string): Round fractions of minutes
* org.el (org-minutes-to-clocksum-string): Round fractions of
minutes.
When adding efforts values in the column view, "0:20" will first be
converted as 0.333333333 hour. When converting the final sum, we
now round the final sum of minutes (e.g. 99.999999999) to get the
correct hour displa (i.e. 1:40 instead of 1:39).
-rw-r--r-- | lisp/org.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/org.el b/lisp/org.el index 9e156c2..7d633ad 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -17463,7 +17463,9 @@ The format is determined by `org-time-clocksum-format', `org-time-clocksum-use-fractional' and `org-time-clocksum-fractional-format' and `org-time-clocksum-use-effort-durations'." - (let ((clocksum "") h d w mo y fmt n) + (let ((clocksum "") + (m (round m)) ; Don't allow fractions of minutes + h d w mo y fmt n) (setq h (if org-time-clocksum-use-effort-durations (cdr (assoc "h" org-effort-durations)) 60) d (if org-time-clocksum-use-effort-durations |