Browse Source

Show "Habit" in modeline when habits are displayed

John Wiegley 15 years ago
parent
commit
d6a2768b48
2 changed files with 9 additions and 1 deletions
  1. 6 0
      lisp/ChangeLog
  2. 3 1
      lisp/org-agenda.el

+ 6 - 0
lisp/ChangeLog

@@ -1,3 +1,9 @@
+2009-10-20  John Wiegley  <jwiegley@gmail.com>
+
+	* org-agenda.el (org-agenda-set-mode-name): Show Habit in the
+	modeline when habits are being displayed (if that module is being
+	loaded).
+
 2009-10-20  Carsten Dominik  <carsten.dominik@gmail.com>
 
 	* org-agenda.el (org-agenda-next-line): New command.

+ 3 - 1
lisp/org-agenda.el

@@ -5643,8 +5643,10 @@ When called with a prefix argument, include all archive files as well."
 		(if org-agenda-entry-text-mode " ETxt"   "")
 		(if org-agenda-include-diary   " Diary"  "")
 		(if org-agenda-use-time-grid   " Grid"   "")
+		(if (and (boundp 'org-habit-show-habits)
+			 org-habit-show-habits) " Habit"   "")
 		(if (consp org-agenda-show-log) " LogAll"
-		    (if org-agenda-show-log " Log" ""))
+		  (if org-agenda-show-log " Log" ""))
 		(if (or org-agenda-filter (get 'org-agenda-filter
 					       :preset-filter))
 		    (concat " {" (mapconcat