Commit 5b881fc1 authored by Derk-Jan Hartman's avatar Derk-Jan Hartman

* Update next/previous item routines. it descends from next chapter to

  next title to next playlistitem. The old code for this was buggy. This
  should work better. Especially for CDDA's, since we previously didn't support
  titles.
parent 56dd78bd
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* controls.m: MacOS X interface plugin * controls.m: MacOS X interface plugin
***************************************************************************** *****************************************************************************
* Copyright (C) 2002-2003 VideoLAN * Copyright (C) 2002-2003 VideoLAN
* $Id: controls.m,v 1.43 2003/06/30 01:52:57 hartman Exp $ * $Id: controls.m,v 1.44 2003/07/09 01:30:41 hartman Exp $
* *
* Authors: Jon Lech Johansen <jon-vl@nanocrew.net> * Authors: Jon Lech Johansen <jon-vl@nanocrew.net>
* Christophe Massiot <massiot@via.ecp.fr> * Christophe Massiot <massiot@via.ecp.fr>
...@@ -158,8 +158,6 @@ ...@@ -158,8 +158,6 @@
vlc_mutex_unlock( &p_playlist->object_lock ); vlc_mutex_unlock( &p_playlist->object_lock );
var_Get( p_playlist->p_input, "prev-chapter", &val ); var_Get( p_playlist->p_input, "prev-chapter", &val );
var_Set( p_playlist->p_input, "prev-chapter", val ); var_Set( p_playlist->p_input, "prev-chapter", val );
p_intf->p_sys->b_input_update = VLC_TRUE;
} }
else if( p_area->i_id > 1 ) else if( p_area->i_id > 1 )
{ {
...@@ -167,8 +165,6 @@ ...@@ -167,8 +165,6 @@
vlc_mutex_unlock( &p_playlist->object_lock ); vlc_mutex_unlock( &p_playlist->object_lock );
var_Get( p_playlist->p_input, "prev-title", &val ); var_Get( p_playlist->p_input, "prev-title", &val );
var_Set( p_playlist->p_input, "prev-title", val ); var_Set( p_playlist->p_input, "prev-title", val );
p_intf->p_sys->b_input_update = VLC_TRUE;
} }
else else
{ {
...@@ -207,24 +203,23 @@ ...@@ -207,24 +203,23 @@
#define p_area p_playlist->p_input->stream.p_selected_area #define p_area p_playlist->p_input->stream.p_selected_area
if( p_area->i_part < p_area->i_part_nb && p_area->i_part_nb > 1 ) if( p_area->i_part < p_area->i_part_nb && p_area->i_part_nb > 1 )
{ {
NSLog(@"next-chapter: %d, all: %d", p_area->i_part, p_area->i_part_nb);
vlc_mutex_unlock( &p_playlist->p_input->stream.stream_lock ); vlc_mutex_unlock( &p_playlist->p_input->stream.stream_lock );
vlc_mutex_unlock( &p_playlist->object_lock ); vlc_mutex_unlock( &p_playlist->object_lock );
var_Get( p_playlist->p_input, "next-chapter", &val ); var_Get( p_playlist->p_input, "next-chapter", &val );
var_Set( p_playlist->p_input, "next-chapter", val ); var_Set( p_playlist->p_input, "next-chapter", val );
p_intf->p_sys->b_input_update = VLC_TRUE;
} }
else if( p_area->i_id < p_playlist->p_input->stream.i_area_nb ) else if( p_area->i_id < p_playlist->p_input->stream.i_area_nb && p_playlist->p_input->stream.i_area_nb > 1 )
{ {
NSLog(@"next-title: %d, all: %d", p_area->i_id, p_playlist->p_input->stream.i_area_nb );
vlc_mutex_unlock( &p_playlist->p_input->stream.stream_lock ); vlc_mutex_unlock( &p_playlist->p_input->stream.stream_lock );
vlc_mutex_unlock( &p_playlist->object_lock ); vlc_mutex_unlock( &p_playlist->object_lock );
var_Get( p_playlist->p_input, "next-title", &val ); var_Get( p_playlist->p_input, "next-title", &val );
var_Set( p_playlist->p_input, "next-title", val ); var_Set( p_playlist->p_input, "next-title", val );
p_intf->p_sys->b_input_update = VLC_TRUE;
} }
else else
{ {
NSLog(@"next-item");
vlc_mutex_unlock( &p_playlist->p_input->stream.stream_lock ); vlc_mutex_unlock( &p_playlist->p_input->stream.stream_lock );
vlc_mutex_unlock( &p_playlist->object_lock ); vlc_mutex_unlock( &p_playlist->object_lock );
playlist_Next( p_playlist ); playlist_Next( p_playlist );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment