? audio_player_handler_options.patch
Index: audio.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/audio/audio.module,v
retrieving revision 1.105.2.2
diff -u -p -r1.105.2.2 audio.module
--- audio.module	13 Jun 2007 22:38:24 -0000	1.105.2.2
+++ audio.module	15 Jun 2007 23:28:09 -0000
@@ -1369,12 +1369,17 @@ function audio_get_players($op = 'names'
  * @return
  *   HTML to play the audio tracks.
  */
-function audio_get_node_player($node) {
+function audio_get_node_player($node, $type = NULL) {
   $output = '';
   // if we've got a URL, setup a player
   if (_audio_allow_play($node)) {
     $format = $node->audio_fileinfo['fileformat'];
-    $playername = variable_get('audio_player_'. $format, '1pixelout');
+    if (!isset($type)) {
+      $playername = variable_get('audio_player_'. $format, '1pixelout');
+    }
+    else {
+      $playername = $type;
+    }
     $player = audio_get_players('name', $playername);
     // try to use the requested player...
     $output = theme($player['theme_node'], $node);
Index: views_audio.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/audio/views_audio.inc,v
retrieving revision 1.6
diff -u -p -r1.6 views_audio.inc
--- views_audio.inc	2 Jan 2007 16:39:07 -0000	1.6
+++ views_audio.inc	15 Jun 2007 23:28:09 -0000
@@ -31,7 +31,13 @@ function audio_views_tables() {
       ),
       'play_link' => array(
         'name' => t('Audio: Player link/flash'),
-        'handler' => 'audio_views_handler_field_player',
+         'handler' => array(
+          'audio_views_handler_field_player'              => t('Site Default Player'),
+          'audio_views_handler_field_player_1pixel'       => t('1pixelout Flash Player'),
+          'audio_views_handler_field_player_xspfbutton'   => t('XSPF Web Music Player Button'),
+          'audio_views_handler_field_player_xspfextended' => t('XSPF Web Music Player - Extended'),
+          'audio_views_handler_field_player_xspfslim'     => t('XSPF Web Music Player - Slim'),
+          ),
         'notafield' => TRUE,
         'sortable' => FALSE,
         'help' => t('This will display a flash player/link.'),
@@ -123,6 +129,31 @@ function audio_views_handler_field_playe
 }
 
 // TODO: profile this code and see if it can be optimized.
+function audio_views_handler_field_player_1pixel($fieldinfo, $fielddata, $value, $data) {
+  $node = node_load($data->nid);
+  return audio_get_node_player($node,'1pixelout');
+}
+
+// TODO: profile this code and see if it can be optimized.
+function audio_views_handler_field_player_xspfbutton($fieldinfo, $fielddata, $value, $data) {
+  $node = node_load($data->nid);
+  return audio_get_node_player($node,'button');
+}
+
+// TODO: profile this code and see if it can be optimized.
+function audio_views_handler_field_player_xspfextended($fieldinfo, $fielddata, $value, $data) {
+  $node = node_load($data->nid);
+  return audio_get_node_player($node,'xspf_extended');
+}
+
+// TODO: profile this code and see if it can be optimized.
+function audio_views_handler_field_player_xspfslim($fieldinfo, $fielddata, $value, $data) {
+  $node = node_load($data->nid);
+  return audio_get_node_player($node,'xspf_slim');
+}
+
+
+// TODO: profile this code and see if it can be optimized.
 function audio_views_handler_field_download($fieldinfo, $fielddata, $value, $data) {
   $node = node_load($data->nid);
   if ($node->url_download) {
