fix awdw solo vicon crash, fix nested clip for binfolders, open edit edl
[goodguy/cinelerra.git] / cinelerra-5.1 / cinelerra / loadfile.C
index e40f716109a14005ba1a0e4ea716afdea5f5ffdb..dce124911df4b2bb5b5505ac84350b12940f407d 100644 (file)
@@ -121,7 +121,8 @@ void LoadFileThread::load_apply()
        if( edl_mode == LOADMODE_EDL_FILEREF )
                mwindow->show_warning(
                        &mwindow->preferences->warn_fileref,
-                       _("Other projects can change this project"));
+                       _("Other projects can change this project\n"
+                         "and this can become a broken link"));
        ArrayList<char*> path_list;
        path_list.set_array_delete();
 
@@ -135,26 +136,19 @@ void LoadFileThread::load_apply()
 
 // No file selected
        if( !path_list.size() ) return;
-
-       if( load_mode == LOADMODE_REPLACE )
-               mwindow->set_filename(path_list[0]);
+       int replaced = load_mode == LOADMODE_REPLACE ||
+            load_mode == LOADMODE_REPLACE_CONCATENATE ? 1 : 0;
 
        mwindow->interrupt_indexes();
        mwindow->gui->lock_window("LoadFileThread::run");
-       mwindow->load_filenames(&path_list, load_mode, edl_mode, 0);
+       mwindow->load_filenames(&path_list, load_mode, edl_mode, replaced);
        mwindow->gui->mainmenu->add_load(path_list.values[0]);
        mwindow->gui->unlock_window();
        path_list.remove_all_objects();
 
        mwindow->save_backup();
-
        mwindow->restart_brender();
-
-       if( load_mode == LOADMODE_REPLACE ||
-           load_mode == LOADMODE_REPLACE_CONCATENATE )
-               mwindow->session->changes_made = 0;
-       else
-               mwindow->session->changes_made = 1;
+       mwindow->session->changes_made = !replaced ? 1 : 0;
 }