comparison gui/ui/gtk/fileselect.c @ 35352:96cda43fe250

Don't unconditionally delete the old playlist. On loading a new file or URL, only delete the old playlist if a new file or URL has been selected. If the dialog has been cancelled, the old playlist shall remain.
author ib
date Thu, 22 Nov 2012 14:13:43 +0000
parents ee265b18d653
children d59cf5c869f4
comparison
equal deleted inserted replaced
35351:92f6fc87ddc8 35352:96cda43fe250
509 if (strcmp(fsVideoFilterNames[l][0], MSGTR_Filter_Playlists) == 0) break; 509 if (strcmp(fsVideoFilterNames[l][0], MSGTR_Filter_Playlists) == 0) break;
510 uiSetFileName( fsSelectedDirectory,fsSelectedFile, fsLastVideoFilterSelected == l ? STREAMTYPE_PLAYLIST : STREAMTYPE_FILE ); 510 uiSetFileName( fsSelectedDirectory,fsSelectedFile, fsLastVideoFilterSelected == l ? STREAMTYPE_PLAYLIST : STREAMTYPE_FILE );
511 selected = g_strconcat(fsSelectedDirectory, "/", fsSelectedFile, NULL); 511 selected = g_strconcat(fsSelectedDirectory, "/", fsSelectedFile, NULL);
512 if (selected) 512 if (selected)
513 { 513 {
514 listMgr(PLAYLIST_DELETE, 0);
514 add_to_gui_playlist(selected, PLAYLIST_ITEM_APPEND); 515 add_to_gui_playlist(selected, PLAYLIST_ITEM_APPEND);
515 g_free(selected); 516 g_free(selected);
516 } 517 }
517 guiInfo.NewPlay=GUI_FILE_NEW; sub_fps=0; 518 guiInfo.NewPlay=GUI_FILE_NEW; sub_fps=0;
518 fs_PersistantHistory( get_current_dir_name_utf8() ); //totem, write into history 519 fs_PersistantHistory( get_current_dir_name_utf8() ); //totem, write into history