if( !p_input )
{
p_input = playlist_CurrentInput( p_playlist );
+
/* Refresh the interface */
if( p_input )
{
- printf("yield\n");
-
msg_Dbg( p_intf, "input has changed, refreshing interface" );
p_intf->p_sys->b_input_update = true;
}
p_intf->p_sys->b_intf_update = true;
p_intf->p_sys->i_play_status = END_S;
msg_Dbg( p_intf, "input has stopped, refreshing interface" );
- printf("release\n");
vlc_object_release( p_input );
p_input = NULL;
}
p_intf->p_sys->b_current_title_update = true;
p_intf->p_sys->b_intf_update = true;
p_intf->p_sys->b_input_update = false;
+ [self setupMenus]; /* Make sure input menu is up to date */
}
if( p_intf->p_sys->b_intf_update )
{
if( p_intf->p_sys->b_current_title_update )
{
- NSString *o_temp;
+ NSString *aString;
+ input_item_t * p_item = input_GetItem( p_input );
+ char * name = input_item_GetNowPlaying( p_item );
- if( p_playlist->status.p_item == NULL )
- {
- vlc_object_release( p_input );
- pl_Release( p_intf );
- goto end;
- }
- if( input_item_GetNowPlaying ( p_playlist->status.p_item->p_input ) )
- o_temp = [NSString stringWithUTF8String:
- input_item_GetNowPlaying ( p_playlist->status.p_item->p_input )];
- else
- o_temp = [NSString stringWithUTF8String:
- p_playlist->status.p_item->p_input->psz_name];
- [self setScrollField: o_temp stopAfter:-1];
- [[[self getControls] getFSPanel] setStreamTitle: o_temp];
+ if( !name )
+ name = input_item_GetName( p_item );
+
+ aString = [NSString stringWithUTF8String:name];
+
+ free(name);
+
+ [self setScrollField: aString stopAfter:-1];
+ [[[self getControls] getFSPanel] setStreamTitle: aString];
[[o_controls getVoutView] updateTitle];
}
vlc_object_release( p_input );
}
+ else if( p_input )
+ {
+ vlc_object_release( p_input );
+ }
else
{
p_intf->p_sys->i_play_status = END_S;
[o_bookmarks release];
if( nib_info_loaded )
+ {
+ [o_info stop];
[o_info release];
-
+ }
+
if( nib_wizard_loaded )
[o_wizard release];