comparison lisp/erc/erc-sound.el @ 84387:4ee03308c9b6

Sync ERC 5.3 (devel) from upstream
author Michael Olson <mwolson@gnu.org>
date Sat, 08 Sep 2007 03:07:09 +0000
parents 85d67fae9a94
children ffc87ddd4025
comparison
equal deleted inserted replaced
84386:869c721b5469 84387:4ee03308c9b6
123 See also `play-sound-file'." 123 See also `play-sound-file'."
124 (let ((filepath (erc-find-file file erc-sound-path))) 124 (let ((filepath (erc-find-file file erc-sound-path)))
125 (if (and (not filepath) erc-default-sound) 125 (if (and (not filepath) erc-default-sound)
126 (setq filepath erc-default-sound)) 126 (setq filepath erc-default-sound))
127 (cond ((and filepath (file-exists-p filepath)) 127 (cond ((and filepath (file-exists-p filepath))
128 (play-sound-file filepath)) 128 (play-sound-file filepath))
129 (t (beep))) 129 (t (beep)))
130 (erc-log (format "Playing sound file %S" filepath)))) 130 (erc-log (format "Playing sound file %S" filepath))))
131 131
132 (defun erc-toggle-sound (&optional arg) 132 (defun erc-toggle-sound (&optional arg)
133 "Toggles playing sounds on and off. With positive argument, 133 "Toggles playing sounds on and off. With positive argument,
140 (message "ERC sound is %s" (if erc-play-sound "ON" "OFF"))) 140 (message "ERC sound is %s" (if erc-play-sound "ON" "OFF")))
141 141
142 142
143 (provide 'erc-sound) 143 (provide 'erc-sound)
144 144
145 ;;; erc-sound.el ends here
146 ;;
147 ;; Local Variables:
148 ;; indent-tabs-mode: t
149 ;; tab-width: 8
150 ;; End:
151
145 ;; arch-tag: 53657d1d-007f-4a20-91c1-588e71cf0cee 152 ;; arch-tag: 53657d1d-007f-4a20-91c1-588e71cf0cee
146 ;;; erc-sound.el ends here