Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] [PATCH] VDR menu entry for libxine front-ends



The attached patch provides the data required for libxine front-ends to be
able to create a menu entry, button or similar for the default vdr MRL. It is
applicable to at least vdr-xine 0.3.4 and touches only input_vdr.c (don't
forget to update the copy in your xine-lib source tree).

(I've prepared a libxine .deb with this patch applied, though I've yet to
make it publicly available.)

-- 
| Darren Salt | d youmustbejoking,demon,co,uk | nr. Ashington,
| Debian,     | s zap,tartarus,org            | Northumberland
| RISC OS     | @                             | Toon Army
|   <URL:http://www.youmustbejoking.demon.co.uk/progs.packages.html>

There's got to be more to life than compile-and-go.
--- vdr-xine-0.3.4.orig/input-plugin/input_vdr.c	2004-05-22 21:08:22.000000000 +0100
+++ vdr-xine-0.3.4/input-plugin/input_vdr.c	2004-06-11 01:10:47.000000000 +0100
@@ -111,6 +111,8 @@
   input_class_t     input_class;
 
   xine_t           *xine;
+  
+  char             *mrls[2];
 } vdr_input_class_t;
 
 
@@ -1337,6 +1339,14 @@
   free (this);
 }
 
+static char ** vdr_class_get_autoplay_list (input_class_t *this_gen,
+					    int *num_files) {
+  vdr_input_class_t *class = (vdr_input_class_t *) this_gen;
+
+  *num_files = 1;
+  return class->mrls;
+}
+
 static void *init_class (xine_t *xine, void *data) {
   vdr_input_class_t  *this;
   
@@ -1346,11 +1356,14 @@
   
   this->xine   = xine;
 
+  this->mrls[0] = "vdr:/tmp/vdr-xine/stream#demux:mpeg_pes";
+  this->mrls[1] = 0;
+
   this->input_class.get_instance       = vdr_class_get_instance;
   this->input_class.get_identifier     = vdr_class_get_identifier;
   this->input_class.get_description    = vdr_class_get_description;
   this->input_class.get_dir            = NULL;
-  this->input_class.get_autoplay_list  = NULL;
+  this->input_class.get_autoplay_list  = vdr_class_get_autoplay_list;
   this->input_class.dispose            = vdr_class_dispose;
   this->input_class.eject_media        = NULL;
 

Home | Main Index | Thread Index