summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2012-04-11 01:14:39 +0200
committerBastien Guerry <bzg@altern.org>2012-04-11 01:14:39 +0200
commit8c4ccab0285781d22993e064cad47474bbf03379 (patch)
tree3a03302d2a7ad49383f62932262e231007486acc
parent5adb7638fe5ab325ba5483cd22df050cbdb24dab (diff)
parent3523533e502f62259c982ac6efaf30fd5962fa64 (diff)
downloadorg-mode-8c4ccab0285781d22993e064cad47474bbf03379.tar.gz
Merge branch 'hotfix'
-rw-r--r--lisp/org-clock.el15
1 files changed, 8 insertions, 7 deletions
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index 27ba8a3..6db24e1 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -219,7 +219,8 @@ auto Automatically, either `all', or `repeat' for repeating tasks"
(const :tag "All task time" all)
(const :tag "Automatically, `all' or since `repeat'" auto)))
-(defcustom org-task-overrun-text nil
+(defvaralias 'org-task-overrun-text 'org-clock-task-overrun-text)
+(defcustom org-clock-task-overrun-text nil
"The extra modeline text that should indicate that the clock is overrun.
The can be nil to indicate that instead of adding text, the clock time
should get a different face (`org-mode-line-clock-overrun').
@@ -501,7 +502,7 @@ pointing to it."
(insert (format "[%c] %-15s %s\n" i cat task))
(cons i marker)))))
-(defvar org-task-overrun nil
+(defvar org-clock-task-overrun nil
"Internal flag indicating if the clock has overrun the planned time.")
(defvar org-clock-update-period 60
"Number of seconds between mode line clock string updates.")
@@ -522,7 +523,7 @@ If not, show simply the clocked time like 01:50."
(work-done-str
(org-propertize
(format org-time-clocksum-format h m)
- 'face (if (and org-task-overrun (not org-task-overrun-text))
+ 'face (if (and org-clock-task-overrun (not org-clock-task-overrun-text))
'org-mode-line-clock-overrun 'org-mode-line-clock)))
(effort-str (format org-time-clocksum-format effort-h effort-m))
(clockstr (org-propertize
@@ -538,7 +539,7 @@ If not, show simply the clocked time like 01:50."
(defun org-clock-update-mode-line ()
(if org-clock-effort
(org-clock-notify-once-if-expired)
- (setq org-task-overrun nil))
+ (setq org-clock-task-overrun nil))
(setq org-mode-line-string
(org-propertize
(let ((clock-string (org-clock-get-clock-string))
@@ -552,10 +553,10 @@ If not, show simply the clocked time like 01:50."
'local-map org-clock-mode-line-map
'mouse-face (if (featurep 'xemacs) 'highlight 'mode-line-highlight)
))
- (if (and org-task-overrun org-task-overrun-text)
+ (if (and org-clock-task-overrun org-clock-task-overrun-text)
(setq org-mode-line-string
(concat (org-propertize
- org-task-overrun-text
+ org-clock-task-overrun-text
'face 'org-mode-line-clock-overrun) org-mode-line-string)))
(force-mode-line-update))
@@ -612,7 +613,7 @@ Notification is shown only once."
(when (org-clocking-p)
(let ((effort-in-minutes (org-duration-string-to-minutes org-clock-effort))
(clocked-time (org-clock-get-clocked-time)))
- (if (setq org-task-overrun
+ (if (setq org-clock-task-overrun
(if (or (null effort-in-minutes) (zerop effort-in-minutes))
nil
(>= clocked-time effort-in-minutes)))