Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Montagne <montagne29@wanadoo.fr>2018-06-05 16:10:33 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-06-05 17:33:46 +0300
commit481cdb08ed6f33a09d0e6843d1024db93c301178 (patch)
tree77166d130bfff2d5dca884676aaeff6bc0758f96 /source/blender/editors/space_sequencer
parent1d97e948d2c4867306e7fb5ce5fccf8b72c13391 (diff)
Cleanup: use new accessors to blendfile path (Main.name).
Diffstat (limited to 'source/blender/editors/space_sequencer')
-rw-r--r--source/blender/editors/space_sequencer/sequencer_add.c4
-rw-r--r--source/blender/editors/space_sequencer/sequencer_edit.c6
2 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/editors/space_sequencer/sequencer_add.c b/source/blender/editors/space_sequencer/sequencer_add.c
index 98370ea9dee..5c332925011 100644
--- a/source/blender/editors/space_sequencer/sequencer_add.c
+++ b/source/blender/editors/space_sequencer/sequencer_add.c
@@ -117,7 +117,7 @@ static void sequencer_generic_invoke_path__internal(bContext *C, wmOperator *op,
Main *bmain = CTX_data_main(C);
char path[FILE_MAX];
BLI_strncpy(path, last_seq->strip->dir, sizeof(path));
- BLI_path_abs(path, bmain->name);
+ BLI_path_abs(path, BKE_main_blendfile_path(bmain));
RNA_string_set(op->ptr, identifier, path);
}
}
@@ -199,7 +199,7 @@ static void seq_load_operator_info(SeqLoadInfo *seq_load, bContext *C, wmOperato
}
if ((is_file != -1) && relative)
- BLI_path_rel(seq_load->path, bmain->name);
+ BLI_path_rel(seq_load->path, BKE_main_blendfile_path(bmain));
if ((prop = RNA_struct_find_property(op->ptr, "frame_end"))) {
diff --git a/source/blender/editors/space_sequencer/sequencer_edit.c b/source/blender/editors/space_sequencer/sequencer_edit.c
index 97ff55bf883..e93a18449b0 100644
--- a/source/blender/editors/space_sequencer/sequencer_edit.c
+++ b/source/blender/editors/space_sequencer/sequencer_edit.c
@@ -3773,7 +3773,7 @@ static int sequencer_change_path_exec(bContext *C, wmOperator *op)
/* TODO, shouldn't 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_path_rel(directory, BKE_main_blendfile_path(bmain));
}
BLI_strncpy(seq->strip->dir, directory, sizeof(seq->strip->dir));
@@ -3889,10 +3889,10 @@ static int sequencer_export_subtitles_invoke(bContext *C, wmOperator *op, const
if (!RNA_struct_property_is_set(op->ptr, "filepath")) {
char filepath[FILE_MAX];
- if (bmain->name[0] == '\0')
+ if (BKE_main_blendfile_path(bmain)[0] == '\0')
BLI_strncpy(filepath, "untitled", sizeof(filepath));
else
- BLI_strncpy(filepath, bmain->name, sizeof(filepath));
+ BLI_strncpy(filepath, BKE_main_blendfile_path(bmain), sizeof(filepath));
BLI_replace_extension(filepath, sizeof(filepath), ".srt");
RNA_string_set(op->ptr, "filepath", filepath);