fix/workaround for blender crashing when running python runs text.clear() in background mode. ideally python api would not use this function.

This commit is contained in:
Campbell Barton 2008-04-25 10:12:32 +00:00
parent 33bbe7f340
commit b94f3d0fcb

@ -1030,7 +1030,8 @@ int txt_find_string(Text *text, char *findstr)
void txt_cut_sel (Text *text)
{
txt_copy_clipboard(text);
if (!G.background) /* Python uses txt_cut_sel, which it should not, working around for now */
txt_copy_clipboard(text);
txt_delete_sel(text);
txt_make_dirty(text);