diff options
-rw-r--r-- | source/blender/editors/space_sequencer/sequencer_edit.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/editors/space_sequencer/sequencer_edit.c b/source/blender/editors/space_sequencer/sequencer_edit.c index bd93a1270f6..da785430d43 100644 --- a/source/blender/editors/space_sequencer/sequencer_edit.c +++ b/source/blender/editors/space_sequencer/sequencer_edit.c @@ -2961,9 +2961,11 @@ void SEQUENCER_OT_change_effect_type(struct wmOperatorType *ot) static int sequencer_change_path_exec(bContext *C, wmOperator *op) { + Main *bmain= CTX_data_main(C); Scene *scene= CTX_data_scene(C); Editing *ed= seq_give_editing(scene, FALSE); Sequence *seq= seq_active_get(scene); + const int is_relative_path= RNA_boolean_get(op->ptr, "relative_path"); if(seq->type == SEQ_IMAGE) { char directory[FILE_MAX]; @@ -2974,6 +2976,12 @@ static int sequencer_change_path_exec(bContext *C, wmOperator *op) return OPERATOR_CANCELLED; RNA_string_get(op->ptr, "directory", directory); + if (is_relative_path) { + /* TODO, shouldnt this already be relative from the filesel? + * (as the 'filepath' is) for now just make relative here, + * but look into changing after 2.60 - campbell */ + BLI_path_rel(directory, bmain->name); + } BLI_strncpy(seq->strip->dir, directory, sizeof(seq->strip->dir)); if(seq->strip->stripdata) { |