Changed frame numbering to only alter hashes if they are in the filename (not the directory name) to fix bug [#10566] File Open Dialog replaces '#' with '0' in directory names.

removed frame numbering from BLI_convertstringcode into its own function (BLI_convertstringframe), many uses of BLI_convertstringcode were passing dummy frames values anyway.
in cases where adding the current frame number to a filename is needed run BLI_convertstringframe(...) after BLI_convertstringcode(...)

There are some cases Im not sure BLI_convertstringframe is needed, these have been commented as todo, but at least have the same functionality they used to.
This commit is contained in:
2008-05-04 09:41:15 +00:00
parent f95c1141db
commit 110f927c63
33 changed files with 164 additions and 128 deletions

View File

@@ -444,7 +444,7 @@ void BPY_rebuild_syspath( void )
}
BLI_strncpy(dirpath, U.pythondir, FILE_MAX);
BLI_convertstringcode(dirpath, G.sce, 0);
BLI_convertstringcode(dirpath, G.sce);
syspath_append(dirpath); /* append to module search path */
BLI_make_file_string("/", modpath, dirpath, "bpymodules");
@@ -1019,7 +1019,7 @@ int BPY_menu_do_python( short menutype, int event )
/* dirs in Blender can be "//", which has a special meaning */
BLI_strncpy(upythondir, U.pythondir, FILE_MAX);
BLI_convertstringcode(upythondir, G.sce, 0); /* if so, this expands it */
BLI_convertstringcode(upythondir, G.sce); /* if so, this expands it */
BLI_make_file_string( "/", filestr, upythondir, pym->filename );
}
else { /* script is in default scripts dir */