diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-02-27 15:01:10 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-02-27 15:01:10 +0300 |
commit | 820570031e3cd2b396b7bcf73f58fe16e20dcd3f (patch) | |
tree | bb3071c06baf726f42cdd9a4f9eb10af5f5ac2d9 | |
parent | bdebf4f2cd263ec22e89bb9b1898aee6c9faaca6 (diff) |
was using wrong global flag for python script disabling in recent commit.
-rw-r--r-- | source/blender/python/intern/bpy_driver.c | 2 | ||||
-rw-r--r-- | source/blender/python/intern/bpy_interface.c | 2 | ||||
-rw-r--r-- | source/blender/windowmanager/intern/wm_operators.c | 4 |
3 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/python/intern/bpy_driver.c b/source/blender/python/intern/bpy_driver.c index a4a28ec53d2..f628e7e8569 100644 --- a/source/blender/python/intern/bpy_driver.c +++ b/source/blender/python/intern/bpy_driver.c @@ -166,7 +166,7 @@ float BPY_pydriver_eval (ChannelDriver *driver) if ((expr == NULL) || (expr[0]=='\0')) return result; - if(!(G.fileflags & G_SCRIPT_AUTOEXEC)) { + if(!(G.f & G_SCRIPT_AUTOEXEC)) { printf("skipping driver '%s', automatic scripts are disabled\n", driver->expression); return result; } diff --git a/source/blender/python/intern/bpy_interface.c b/source/blender/python/intern/bpy_interface.c index db31bd01a7a..ec43118d9fc 100644 --- a/source/blender/python/intern/bpy_interface.c +++ b/source/blender/python/intern/bpy_interface.c @@ -631,7 +631,7 @@ void BPY_load_user_modules(bContext *C) for(text=CTX_data_main(C)->text.first; text; text= text->id.next) { if(text->flags & TXT_ISSCRIPT && BLI_testextensie(text->id.name+2, ".py")) { - if(!(G.fileflags & G_SCRIPT_AUTOEXEC)) { + if(!(G.f & G_SCRIPT_AUTOEXEC)) { printf("scripts disabled for \"%s\", skipping '%s'\n", bmain->name, text->id.name+2); } else { diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c index 3d8152ce76a..0938c583d2e 100644 --- a/source/blender/windowmanager/intern/wm_operators.c +++ b/source/blender/windowmanager/intern/wm_operators.c @@ -1357,9 +1357,9 @@ static int wm_open_mainfile_exec(bContext *C, wmOperator *op) G.fileflags |= G_FILE_NO_UI; if(RNA_boolean_get(op->ptr, "use_scripts")) - G.fileflags |= G_SCRIPT_AUTOEXEC; + G.f |= G_SCRIPT_AUTOEXEC; else - G.fileflags &= ~G_SCRIPT_AUTOEXEC; + G.f &= ~G_SCRIPT_AUTOEXEC; // XXX wm in context is not set correctly after WM_read_file -> crash // do it before for now, but is this correct with multiple windows? |