[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Orgmode] [PATCH] org-show-notification will use todochiku.el if availab
From: |
Jason F. McBrayer |
Subject: |
[Orgmode] [PATCH] org-show-notification will use todochiku.el if available |
Date: |
Wed, 22 Jul 2009 14:43:30 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) |
This is a little patch to let org-show-notification (in org-clock.el)
use the package [todochiku.el] if available. This means that if
todochiku has been set up correctly, org-show-notification will work
with Growl (on MacOS) or Snarl (on MSWindows), as well as libnotify (on
*ix).
[todochiku.el] http://www.emacswiki.org/emacs-se/ToDoChiKu
---
lisp/org-clock.el | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/lisp/org-clock.el b/lisp/org-clock.el
index 594d3cf..5428aa1 100644
--- a/lisp/org-clock.el
+++ b/lisp/org-clock.el
@@ -440,9 +440,12 @@ Notification is shown only once."
(setq org-clock-notification-was-shown nil)))))
(defun org-show-notification (notification)
- "Show notification. Use libnotify, if available."
- (if (org-program-exists "notify-send")
- (start-process "emacs-timer-notification" nil "notify-send"
notification))
+ "Show notification. Use todochiku.el or libnotify, if available."
+ (if (fboundp 'todochiku-message)
+ (todochiku-message "org-mode notification" notification
+ (todochiku-icon 'emacs))
+ (if (org-program-exists "notify-send")
+ (start-process "emacs-timer-notification" nil "notify-send"
notification)))
;; In any case, show in message area
(message notification))
--
1.6.1.2
--
+-----------------------------------------------------------+
| Jason F. McBrayer address@hidden |
| If someone conquers a thousand times a thousand others in |
| battle, and someone else conquers himself, the latter one |
| is the greatest of all conquerors. --- The Dhammapada |
- [Orgmode] [PATCH] org-show-notification will use todochiku.el if available,
Jason F. McBrayer <=