]> git.sesse.net Git - vlc/blobdiff - modules/gui/wxwidgets/playlist_manager.cpp
Replace vlc_object_find() and vlc_object_release() of VLC_OBJECT_PLAYLIST with pl_Yie...
[vlc] / modules / gui / wxwidgets / playlist_manager.cpp
index d8d77e982ac29b75c3f0ca548c5068c52cbf0c80..d853bf9b7eda911fe1f69f103a605bed92942028 100644 (file)
@@ -111,8 +111,7 @@ PlaylistManager::PlaylistManager( intf_thread_t *_p_intf, wxWindow *p_parent ):
     i_cached_item_id = -1;
     i_update_counter = 0;
 
-    p_playlist = (playlist_t *)
-        vlc_object_find( p_intf, VLC_OBJECT_PLAYLIST, FIND_ANYWHERE );
+    p_playlist = pl_Yield( p_intf );
     if( p_playlist == NULL ) return;
 
     var_Create( p_intf, "random", VLC_VAR_BOOL | VLC_VAR_DOINHERIT );
@@ -188,7 +187,7 @@ PlaylistManager::~PlaylistManager()
     var_DelCallback( p_playlist, "intf-change", PlaylistChanged, this );
     var_DelCallback( p_playlist, "item-append", ItemAppended, this );
     var_DelCallback( p_playlist, "item-deleted", ItemDeleted, this );
-    vlc_object_release( p_playlist );
+    pl_Release( p_playlist );
 }
 
 /*****************************************************************************