This is another test
[gnus] / lisp / gnus-audio.el
index af9e00a..f3bb686 100644 (file)
@@ -2,7 +2,6 @@
 ;; Copyright (C) 1996 Free Software Foundation
 
 ;; Author: Steven L. Baur <steve@miranova.com>
-;; Keywords: news
 
 ;; This file is part of GNU Emacs.
 
 ;;; Commentary:
 ;; This file provides access to sound effects in Gnus.
 ;; Prerelease:  This file is partially stripped to support earcons.el
-;; You can safely ignore most of it until Red Gnus. **Evil Laugh**
+;; You can safely ignore most of it until Red Gnus.  **Evil Laugh**
 ;;; Code:
 
-(if (null (boundp 'running-xemacs))
-    (defvar running-xemacs (string-match "XEmacs\\|Lucid" emacs-version)))
+(when (null (boundp 'running-xemacs))
+  (defvar running-xemacs (string-match "XEmacs\\|Lucid" emacs-version)))
 
 (require 'nnheader)
 (eval-when-compile (require 'cl))
   "The directory containing the Sound Files.")
 
 (defvar gnus-audio-au-player "/usr/bin/showaudio"
-  "Executable program for playing sun AU format sound files")
-(defvar gnus-audio-wav-player "/usr/local/bin/play"
-  "Executable program for playing WAV files")
+  "Executable program for playing sun AU format sound files.")
 
+(defvar gnus-audio-wav-player "/usr/local/bin/play"
+  "Executable program for playing WAV files.")
 
-;;; The following isn't implemented yet.  Wait for Red Gnus.
+;;; The following isn't implemented yet.  Wait for Millennium Gnus.
 ;(defvar gnus-audio-effects-enabled t
 ;  "When t, Gnus will use sound effects.")
 ;(defvar gnus-audio-enable-hooks nil
 
 
 ;;;###autoload
-;(defun gnus-audio-enable-sound ()
+                                       ;(defun gnus-audio-enable-sound ()
 ;  "Enable Sound Effects for Gnus."
 ;  (interactive)
 ;  (setq gnus-audio-effects-enabled t)
-;  (run-hooks gnus-audio-enable-hooks))
+;  (gnus-run-hooks gnus-audio-enable-hooks))
 
 ;;;###autoload
-;(defun gnus-audio-disable-sound ()
+                                       ;(defun gnus-audio-disable-sound ()
 ;  "Disable Sound Effects for Gnus."
 ;  (interactive)
 ;  (setq gnus-audio-effects-enabled nil)
-;  (run-hooks gnus-audio-disable-hooks))
+;  (gnus-run-hooks gnus-audio-disable-hooks))
 
 ;;;###autoload
 (defun gnus-audio-play (file)
                      (concat gnus-audio-directory file))))
     (when (file-exists-p sound-file)
       (if gnus-audio-inline-sound
-         (play-sound-file (concat gnus-audio-directory sound-file))
+         (play-sound-file sound-file)
        (cond ((string-match "\\.wav$" sound-file)
               (call-process gnus-audio-wav-player
-                            (concat gnus-audio-directory sound-file)
+                            sound-file
                             0
-                            nil))
+                            nil
+                            sound-file))
              ((string-match "\\.au$" sound-file)
               (call-process gnus-audio-au-player
-                            (concat gnus-audio-directory sound-file)
+                            sound-file
                             0
-                            nil)))))))
+                            nil
+                            sound-file)))))))
 
 
 ;;; The following isn't implemented yet, wait for Red Gnus
-;(defun gnus-audio-startrek-sounds ()
+                                       ;(defun gnus-audio-startrek-sounds ()
 ;  "Enable sounds from Star Trek the original series."
 ;  (interactive)
 ;  (setq gnus-audio-busy-sound "working.au")