[vlc-commits] skins2: show the human readible name of the playlist item by default.

Jean-Paul Saman git at videolan.org
Mon Mar 12 15:46:01 CET 2012


vlc | branch: master | Jean-Paul Saman <jean-paul.saman at m2x.nl> | Mon Mar 12 14:53:20 2012 +0100| [3444aef7c7d1523e184a2a11d8f62675ef17700e] | committer: Jean-Paul Saman

skins2: show the human readible name of the playlist item by default.

The skins2 GUI showed the URI by default, but this is not what most people expect.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3444aef7c7d1523e184a2a11d8f62675ef17700e
---

 modules/gui/skins2/vars/playtree.cpp |    9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/modules/gui/skins2/vars/playtree.cpp b/modules/gui/skins2/vars/playtree.cpp
index 918d4b1..6ce1b86 100644
--- a/modules/gui/skins2/vars/playtree.cpp
+++ b/modules/gui/skins2/vars/playtree.cpp
@@ -116,7 +116,9 @@ void Playtree::onUpdateItem( int id )
             return;
         }
 
-        UString *pName = new UString( getIntf(), pNode->p_input->psz_name );
+        char *psz_name = input_item_GetTitleFbName( pNode->p_input );
+        UString *pName = new UString( getIntf(), psz_name );
+        free(psz_name);
         playlist_Unlock( m_pPlaylist );
 
         if( *pName != *(it->getString()) )
@@ -217,8 +219,9 @@ void Playtree::onAppend( playlist_add_t *p_add )
         for( pos = 0; pos < pItem->p_parent->i_children; pos++ )
             if( pItem->p_parent->pp_children[pos] == pItem ) break;
 
-        UString *pName = new UString( getIntf(),
-                                      pItem->p_input->psz_name );
+        char *psz_name = input_item_GetTitleFbName( pItem->p_input );
+        UString *pName = new UString( getIntf(), psz_name );
+        free( psz_name );
 
         playlist_item_t* current = playlist_CurrentPlayingItem( m_pPlaylist );
 



More information about the vlc-commits mailing list