Forráskód Böngészése

org-clock.el: Make org-notify support macOS notification

* lisp/org-clock.el (org-show-notification): Add support for macOS
notification.
stardiviner 3 éve
szülő
commit
b80b0a517d
1 módosított fájl, 4 hozzáadás és 0 törlés
  1. 4 0
      lisp/org-clock.el

+ 4 - 0
lisp/org-clock.el

@@ -859,6 +859,10 @@ use libnotify if available, or fall back on a message."
 	    org-show-notification-timeout
 	    nil
 	    (lambda () (w32-notification-close id)))))
+        ((fboundp 'ns-do-applescript)
+         (ns-do-applescript
+          (format "display notification \"%s\" with title \"Org mode notification\""
+                  (replace-regexp-in-string "\"" "#" notification))))
 	((fboundp 'notifications-notify)
 	 (notifications-notify
 	  :title "Org mode message"