diff options
author | Campbell Barton <ideasman42@gmail.com> | 2006-10-12 21:35:59 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2006-10-12 21:35:59 +0400 |
commit | b62232b5be202a8701a86d0537a793552b12dd73 (patch) | |
tree | c229921e3555bb348dfde1ca08e811a0c42ebb61 | |
parent | 15a7f590a7270e0f5b7bf59c78297865c88ea6e0 (diff) |
fix for [ #4868 ] script window "save as" uses blend path instead of script path.
2 line fix, if text->name is not NULL its used for the path (text->name IS the path) otherwise the ID name is used.
-rw-r--r-- | source/blender/src/drawtext.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/src/drawtext.c b/source/blender/src/drawtext.c index eeb9ff90c78..748cb0fffe4 100644 --- a/source/blender/src/drawtext.c +++ b/source/blender/src/drawtext.c @@ -1082,7 +1082,10 @@ void txt_write_file(Text *text) /* Do we need to get a filename? */ if (text->flags & TXT_ISMEM) { - activate_fileselect(FILE_SPECIAL, "SAVE TEXT FILE", G.sce, save_mem_text); + if (text->name) + activate_fileselect(FILE_SPECIAL, "SAVE TEXT FILE", text->name, save_mem_text); + else + activate_fileselect(FILE_SPECIAL, "SAVE TEXT FILE", text->id.name+2, save_mem_text); return; } |