intf_thread_t * p_intf = VLCIntf;
playlist_t * p_playlist = pl_Yield( p_intf );
- vlc_mutex_lock( &p_playlist->object_lock );
+ vlc_object_lock( p_playlist );
if( playlist_IsEmpty( p_playlist ) )
{
- vlc_mutex_unlock( &p_playlist->object_lock );
+ vlc_object_unlock( p_playlist );
vlc_object_release( p_playlist );
[o_main intfOpenFileGeneric: (id)sender];
}
else
{
- vlc_mutex_unlock( &p_playlist->object_lock );
+ vlc_object_unlock( p_playlist );
vlc_object_release( p_playlist );
}
config_PutInt( p_playlist, "random", 0 );
}
- p_intf->p_sys->b_playmode_update = VLC_TRUE;
- p_intf->p_sys->b_intf_update = VLC_TRUE;
+ p_intf->p_sys->b_playmode_update = true;
+ p_intf->p_sys->b_intf_update = true;
vlc_object_release( p_playlist );
}
[self repeatOne];
/* prepare core communication */
- repeating.b_bool = VLC_TRUE;
- looping.b_bool = VLC_FALSE;
+ repeating.b_bool = true;
+ looping.b_bool = false;
config_PutInt( p_playlist, "repeat", 1 );
config_PutInt( p_playlist, "loop", 0 );
[self repeatAll];
/* prepare core communication */
- repeating.b_bool = VLC_FALSE;
- looping.b_bool = VLC_TRUE;
+ repeating.b_bool = false;
+ looping.b_bool = true;
config_PutInt( p_playlist, "repeat", 0 );
config_PutInt( p_playlist, "loop", 1 );
[self repeatOff];
/* prepare core communication */
- repeating.b_bool = VLC_FALSE;
- looping.b_bool = VLC_FALSE;
+ repeating.b_bool = false;
+ looping.b_bool = false;
config_PutInt( p_playlist, "repeat", 0 );
config_PutInt( p_playlist, "loop", 0 );
/* communicate with core and the main intf loop */
var_Set( p_playlist, "repeat", repeating );
var_Set( p_playlist, "loop", looping );
- p_intf->p_sys->b_playmode_update = VLC_TRUE;
- p_intf->p_sys->b_intf_update = VLC_TRUE;
+ p_intf->p_sys->b_playmode_update = true;
+ p_intf->p_sys->b_intf_update = true;
vlc_object_release( p_playlist );
}
config_PutInt( p_playlist, "repeat", 0 );
}
- p_intf->p_sys->b_playmode_update = VLC_TRUE;
- p_intf->p_sys->b_intf_update = VLC_TRUE;
+ p_intf->p_sys->b_playmode_update = true;
+ p_intf->p_sys->b_intf_update = true;
vlc_object_release( p_playlist );
}
config_PutInt( p_playlist, "loop", 0 );
}
- p_intf->p_sys->b_playmode_update = VLC_TRUE;
- p_intf->p_sys->b_intf_update = VLC_TRUE;
+ p_intf->p_sys->b_playmode_update = true;
+ p_intf->p_sys->b_intf_update = true;
vlc_object_release( p_playlist );
}
[self setupVarMenu: o_menu forMenuItem: o_mi target:p_object
var:psz_variable selector:pf_callback];
- if( text.psz_string ) free( text.psz_string );
+ free( text.psz_string );
return;
}
break;
default:
- if( text.psz_string ) free( text.psz_string );
+ free( text.psz_string );
return;
}
if( ( i_type & VLC_VAR_TYPE ) == VLC_VAR_STRING ) free( val.psz_string );
- if( text.psz_string ) free( text.psz_string );
+ free( text.psz_string );
}
var_Set( p_object, strdup([o_data name]), [o_data value] );
vlc_object_release( p_object );
[o_pool release];
- return VLC_TRUE;
+ return true;
}
[o_pool release];
return VLC_EGENERIC;
intf_thread_t * p_intf = VLCIntf;
playlist_t * p_playlist = pl_Yield( p_intf );
- vlc_mutex_lock( &p_playlist->object_lock );
+ vlc_object_lock( p_playlist );
#define p_input p_playlist->p_input
[o_main setupMenus]; /* Make sure video menu is up to date */
}
- vlc_mutex_unlock( &p_playlist->object_lock );
+ vlc_object_unlock( p_playlist );
vlc_object_release( p_playlist );
return( bEnabled );