+
+ UpdateFileInfo();
+}
+
+void FileInfo::UpdateFileInfo()
+{
+ input_thread_t *p_input = p_intf->p_sys->p_input;
+
+ if( !p_input || p_input->b_dead || !p_input->psz_name )
+ {
+ if( fileinfo_root )
+ {
+ fileinfo_root_label = wxT("");
+ fileinfo_tree->DeleteChildren( fileinfo_root );
+ }
+ return;
+ }
+
+ if( !fileinfo_root )
+ {
+ /* On linux, the first argument of wxTreeCtrl::AddRoot() can be
+ * retrieved with the GetItemText() method, but it doesn't work on
+ * Windows when the wxTR_HIDE_ROOT style is set. That's why we need to
+ * use the fileinfo_root_label variable... */
+ fileinfo_root = fileinfo_tree->AddRoot( wxL2U(p_input->psz_name) );
+ fileinfo_root_label = wxL2U(p_input->psz_name);
+ }
+ else if( fileinfo_root_label == wxL2U(p_input->psz_name) )
+ {