X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=modules%2Fgui%2Fwxwidgets%2Fdialogs%2Fplaylist.cpp;h=860ad376013e8f98434617b3de7394b54066e833;hb=c17290dc45902a3b93c90f3e033f4f2671b69134;hp=c0bc2521f06b0e2ca82cd4d6d5b4e7d7655ec2a8;hpb=7e39490ef6e92153bb5761fd6edcf01a101cfc61;p=vlc diff --git a/modules/gui/wxwidgets/dialogs/playlist.cpp b/modules/gui/wxwidgets/dialogs/playlist.cpp index c0bc2521f0..860ad37601 100644 --- a/modules/gui/wxwidgets/dialogs/playlist.cpp +++ b/modules/gui/wxwidgets/dialogs/playlist.cpp @@ -4,8 +4,8 @@ * Copyright (C) 2000-2005 the VideoLAN team * $Id$ * - * Authors: Olivier Teulière - * Clément Stenac + * Authors: Olivier Teulière + * Clément Stenac * * This program is free software; you can redistribute it and/OR MODIFy * it under the terms of the GNU General Public License as published by @@ -19,7 +19,7 @@ * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA. + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA. *****************************************************************************/ /***************************************************************************** @@ -47,6 +47,8 @@ #include #include +#include + #define HELP_SHUFFLE N_( "Shuffle" ) #define HELP_LOOP N_( "Repeat All" ) #define HELP_REPEAT N_( "Repeat One" ) @@ -60,9 +62,9 @@ static int PlaylistNext( vlc_object_t *, const char *, static int ItemChanged( vlc_object_t *, const char *, vlc_value_t, vlc_value_t, void * ); static int ItemAppended( vlc_object_t *p_this, const char *psz_variable, - vlc_value_t oval, vlc_value_t nval, void *param ); + vlc_value_t oval, vlc_value_t nval, void *param ); static int ItemDeleted( vlc_object_t *p_this, const char *psz_variable, - vlc_value_t oval, vlc_value_t nval, void *param ); + vlc_value_t oval, vlc_value_t nval, void *param ); /***************************************************************************** * Event Table. @@ -492,8 +494,7 @@ void Playlist::UpdateTreeItem( wxTreeItemId item ) wxString msg; wxString duration = wxU( "" ); char *psz_author = vlc_input_item_GetInfo( &p_item->input, - _("Meta-information"), - _("Artist")); + _(VLC_META_INFO_CAT), _(VLC_META_ARTIST) ); if( !psz_author ) { UnlockPlaylist( p_intf->p_sys, p_playlist ); @@ -517,7 +518,7 @@ void Playlist::UpdateTreeItem( wxTreeItemId item ) else { msg = wxString(wxU( psz_author )) + wxT(" - ") + - wxString(wxU(p_item->input.psz_name)) + duration; + wxString(wxU(p_item->input.psz_name)) + duration; } free( psz_author ); treectrl->SetItemText( item , msg ); @@ -874,7 +875,7 @@ void Playlist::DeleteTreeItem( wxTreeItemId item ) void Playlist::DeleteItem( int item_id ) { - playlist_LockDelete( p_playlist, item_id ); + playlist_Delete( p_playlist, item_id ); } void Playlist::DeleteNode( playlist_item_t *p_item ) @@ -1016,6 +1017,7 @@ void Playlist::OnSearch( wxCommandEvent& WXUNUSED(event) ) { search_current = found; treectrl->EnsureVisible( found ); + treectrl->UnselectAll(); treectrl->SelectItem( found, true ); } } @@ -1100,7 +1102,8 @@ void Playlist::OnActivateItem( wxTreeEvent& event ) else { p_node = p_item2; - if( p_node && p_node->i_children > 0 && + p_item = NULL; +/* if( p_node && p_node->i_children > 0 && p_node->pp_children[0]->i_children == -1) { p_item = p_node->pp_children[0]; @@ -1108,7 +1111,7 @@ void Playlist::OnActivateItem( wxTreeEvent& event ) else { p_item = NULL; - } + }*/ } playlist_Control( p_playlist, PLAYLIST_VIEWPLAY, i_current_view,