]> git.sesse.net Git - vlc/commitdiff
Use vlc_object_get_name()
authorRémi Denis-Courmont <remi@remlab.net>
Sat, 5 Sep 2009 08:00:07 +0000 (11:00 +0300)
committerRémi Denis-Courmont <remi@remlab.net>
Sat, 5 Sep 2009 08:15:24 +0000 (11:15 +0300)
modules/gui/ncurses.c
modules/gui/qt4/dialogs/messages.cpp

index 67afea88991a953f8e2d594ba8a08b6580a4a825..b05f93d10faf3d151401a4aa858f62f0fa087b24 100644 (file)
@@ -1453,11 +1453,11 @@ static void MainBoxWrite( intf_thread_t *p_intf, int l, int x, const char *p_fmt
 
 static void DumpObject( intf_thread_t *p_intf, int *l, vlc_object_t *p_obj, int i_level )
 {
-    /*if( p_obj->psz_object_name )
+    const char *psz_name = vlc_object_get_name( p_obj );
+    if( psz_name )
         MainBoxWrite( p_intf, (*l)++, 1 + 2 * i_level, "%s \"%s\" (%p)",
-                p_obj->psz_object_type, p_obj->psz_object_name,
-                p_obj );
-    else*/
+                p_obj->psz_object_type, psz_name, p_obj );
+    else
         MainBoxWrite( p_intf, (*l)++, 1 + 2 * i_level, "%s (%o)",
                 p_obj->psz_object_type, p_obj );
 
index 06442e5fd629cf8a6580bf0746363751bb7535d8..622cc2fd3a5e1faf5c8c562b8c61de597c600a8e 100644 (file)
@@ -278,11 +278,12 @@ void MessagesDialog::buildTree( QTreeWidgetItem *parentItem,
     else
         item = new QTreeWidgetItem( modulesTree );
 
-    /*if( p_obj->psz_object_name )
+    const char *name = vlc_object_get_name( p_obj );
+    if( name != NULL )
         item->setText( 0, qfu( p_obj->psz_object_type ) + " \"" +
-                       qfu( p_obj->psz_object_name ) + "\" (" +
+                       qfu( name ) + "\" (" +
                        QString::number((uintptr_t)p_obj) + ")" );
-    else*/
+    else
         item->setText( 0, qfu( p_obj->psz_object_type ) + " (" +
                        QString::number((uintptr_t)p_obj) + ")" );