From a3c373a1bf65c29f2d74a4b401844f099de4253f Mon Sep 17 00:00:00 2001 From: Bastien Date: Sun, 26 Jan 2020 16:49:11 +0100 Subject: [PATCH] org-clock.el: Explicitely require 'notifications * lisp/org-clock.el (org-show-notification): Explicitely require 'notifications and remove w32-related code. --- lisp/org-clock.el | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lisp/org-clock.el b/lisp/org-clock.el index 1e355670a..a95c85437 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -808,6 +808,7 @@ If PLAY-SOUND is non-nil, it overrides `org-clock-sound'." "Show notification. Use `org-show-notification-handler' if defined, use libnotify if available, or fall back on a message." + (ignore-errors (require 'notifications)) (cond ((functionp org-show-notification-handler) (funcall org-show-notification-handler notification)) ((stringp org-show-notification-handler) @@ -823,11 +824,6 @@ use libnotify if available, or fall back on a message." ((executable-find "notify-send") (start-process "emacs-timer-notification" nil "notify-send" notification)) - ((string-equal system-type "windows-nt") - (w32-notification-close (w32-notification-notify - :title "Org mode message" - :body notification - :urgency 'low))) ;; Maybe the handler will send a message, so only use message as ;; a fall back option (t (message "%s" notification))))