forked from bartvdbraak/blender
- [win32] now really using the directory Blender is installed in. My patch was kinda incomplete, but aphex_ (Simon) was kind enough to point out the lines to edit :)
This commit is contained in:
parent
f2f514d1d4
commit
1126706d2e
@ -509,10 +509,10 @@ char *BLI_gethome(void) {
|
||||
{
|
||||
//strcat(dir,".blender/");
|
||||
strcpy(tmpdir,dir);
|
||||
strcat(tmpdir,".blender/.B.blend");
|
||||
strcat(tmpdir,"/.blender/.B.blend");
|
||||
if (BLI_exists(tmpdir))
|
||||
{
|
||||
strcat(dir,".blender/");
|
||||
strcat(dir,"/.blender/");
|
||||
return(dir);
|
||||
}
|
||||
}
|
||||
|
@ -51,9 +51,12 @@
|
||||
int BLI_getInstallationDir( char * str ) {
|
||||
char dir[FILE_MAXDIR];
|
||||
char file[FILE_MAXFILE];
|
||||
int a;
|
||||
|
||||
GetModuleFileName(NULL,str,FILE_MAXDIR+FILE_MAXFILE);
|
||||
BLI_split_dirfile(str,dir,file);
|
||||
a = strlen(dir);
|
||||
if(dir[a-1] == '\\') dir[a-1]=0;
|
||||
|
||||
strcpy(str,dir);
|
||||
|
||||
|
@ -1612,7 +1612,7 @@ int BLO_write_file(char *dir, int write_flags, char **error_r)
|
||||
BLI_getInstallationDir(tmpdir);
|
||||
|
||||
if(BLI_exists(tmpdir))
|
||||
strcat(tmpdir,".blender/");
|
||||
strcat(tmpdir,"/.blender/");
|
||||
|
||||
BLI_make_file_string(G.sce, userfilename, tmpdir, ".B.blend");
|
||||
#else
|
||||
|
@ -423,7 +423,7 @@ void BIF_write_homefile(void)
|
||||
char dir[FILE_MAXDIR+FILE_MAXFILE];
|
||||
BLI_getInstallationDir(dir);
|
||||
|
||||
strcat(dir,".blender/");
|
||||
strcat(dir,"/.blender/");
|
||||
|
||||
BLI_make_file_string("/", tstr, dir, ".B.blend");
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user