diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-03-26 14:35:57 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-03-26 14:35:57 +0300 |
commit | 991f6f5998314635de8a096f78906715684aae7f (patch) | |
tree | e38446fb2a893cc1012c9dfc0b45b2f9d5ec7a05 /source/blender | |
parent | b1475ae2c6e991ee4f9b1eb73f207f7b91a194c2 (diff) |
- game engine checking for autoexec was using the wrong global flag.
- 'Trusted Source' option was being overwritten on read making it usless.
Diffstat (limited to 'source/blender')
-rw-r--r-- | source/blender/windowmanager/intern/wm_files.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c index 2959bb4c179..f79b083857e 100644 --- a/source/blender/windowmanager/intern/wm_files.c +++ b/source/blender/windowmanager/intern/wm_files.c @@ -261,6 +261,7 @@ void WM_read_file(bContext *C, char *name, ReportList *reports) /* we didn't succeed, now try to read Blender file */ if (retval== 0) { + int G_f= G.f; ListBase wmbase; /* put aside screens to match with persistant windows later */ @@ -270,6 +271,11 @@ void WM_read_file(bContext *C, char *name, ReportList *reports) retval= BKE_read_file(C, name, NULL, reports); G.save_over = 1; + /* this flag is initialized by the operator but overwritten on read. + * need to re-enable it here else drivers + registered scripts wont work. */ + if(G_f & G_SCRIPT_AUTOEXEC) G.f |= G_SCRIPT_AUTOEXEC; + else G.f &= ~G_SCRIPT_AUTOEXEC; + /* match the read WM with current WM */ wm_window_match_do(C, &wmbase); WM_check(C); /* opens window(s), checks keymaps */ |