APPROVE COMMIT
NOTE: This patch has been committed.
xwem patch:
ChangeLog files diff command: cvs -q diff -U 0
Files affected: ChangeLog
Source files diff command: cvs -q diff -uN
Files affected: utils/xwem-worklog.el
Index: ChangeLog
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/xwem/ChangeLog,v
retrieving revision 1.57
diff -u -U0 -r1.57 ChangeLog
--- ChangeLog 3 Dec 2004 21:48:09 -0000 1.57
+++ ChangeLog 3 Dec 2004 23:10:34 -0000
@@ -2,0 +3,8 @@
+ From Richard Klinda <ignotus(a)hixsplit.hu>
+ * utils/xwem-worklog.el (xwem-worklog-meaning-update-time): Take
+ into account the situation where the day's end hour can be smaller
+ than the day's start hour.
+ (xwem-worklog-generate-percentage-spec): Ditto.
+
+2004-12-04 Steve Youngs <steve(a)youngs.au.com>
+
Index: utils/xwem-worklog.el
===================================================================
RCS file: /pack/xemacscvs/XEmacs/packages/xemacs-packages/xwem/utils/xwem-worklog.el,v
retrieving revision 1.4
diff -u -u -r1.4 xwem-worklog.el
--- utils/xwem-worklog.el 3 Dec 2004 12:17:18 -0000 1.4
+++ utils/xwem-worklog.el 3 Dec 2004 23:10:21 -0000
@@ -1239,7 +1239,12 @@
(defun xwem-worklog-generate-percentage-spec (sector-width &optional no-labels
no-yoff)
"Generates percentage diagram spec.
If NO-LABELS is non-nil, labels will be avoided."
- (let* ((today-seconds (* 60.0 60 xwem-worklog-day-length))
+ (let* ((today-seconds
+ (* 60.0 60
+ (if (> xwem-worklog-day-ends xwem-worklog-day-start)
+ (- xwem-worklog-day-ends xwem-worklog-day-start)
+ (- (+ 24 xwem-worklog-day-ends)
+ xwem-worklog-day-start))))
(spec1 (mapcar (lambda (task)
(let* ((td (xwem-worklog-lookup-description
(xwem-worklog-task-name task)))
(tt (xwem-worklog-get-today-time task))
@@ -1319,7 +1324,10 @@
(defun xwem-worklog-meaning-update-time ()
"Return seconds."
- (/ (* 60 60 xwem-worklog-day-length) 100))
+ (if (> xwem-worklog-day-ends xwem-worklog-day-start)
+ (/ (* 60 60 (- xwem-worklog-day-ends xwem-worklog-day-start)) 100)
+ (/ (* 60 60 (- (+ 24 xwem-worklog-day-ends) xwem-worklog-day-start))
+ 100)))
(define-xwem-deffered xwem-worklog-dockapp-update (dockapp)
"Update worklog dockapp."
--
|---<Steve Youngs>---------------<GnuPG KeyID: A94B3003>---|
| In space, |
| No one can hear you rip a stinky |
|---------------------------------------<steve(a)xwem.org>---|
Show replies by date