changeset 19764:499e5525d706

if no track number specified play the whole disc, or the menus can't be shown at start
author nicodvb
date Sat, 09 Sep 2006 20:51:29 +0000
parents b3855eac66ca
children 547019970a2d
files stream/stream_dvdnav.c
diffstat 1 files changed, 4 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/stream/stream_dvdnav.c	Sat Sep 09 19:35:55 2006 +0000
+++ b/stream/stream_dvdnav.c	Sat Sep 09 20:51:29 2006 +0000
@@ -23,7 +23,7 @@
   int track;
   char* device;
 } stream_priv_dflts = {
-  1,
+  0,
   NULL
 };
 
@@ -405,10 +405,13 @@
     return STREAM_UNSUPORTED;
   }
 
+  if(p->track > 0) {
   if(dvdnav_title_play(dvdnav_priv->dvdnav, p->track) != DVDNAV_STATUS_OK) {
     mp_msg(MSGT_OPEN,MSGL_FATAL,"dvdnav_stream, couldn't select title %d, error '%s'\n", p->track, dvdnav_err_to_string(dvdnav_priv->dvdnav));
     return STREAM_UNSUPORTED;
   }
+  } else 
+    mp_msg(MSGT_OPEN,MSGL_INFO,"dvdnav_stream, you didn't specify a track number (as in dvdnav://1), playing whole disc\n");
 
   stream->sector_size = 2048;
   stream->flags = STREAM_READ | STREAM_SEEK;