Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/windowmanager/intern/wm_files.c')
-rw-r--r--source/blender/windowmanager/intern/wm_files.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c
index b54e70a7640..141c51adc58 100644
--- a/source/blender/windowmanager/intern/wm_files.c
+++ b/source/blender/windowmanager/intern/wm_files.c
@@ -1,4 +1,4 @@
-/**
+/*
* $Id$
*
* ***** BEGIN GPL LICENSE BLOCK *****
@@ -25,6 +25,11 @@
* ***** END GPL LICENSE BLOCK *****
*/
+/** \file blender/windowmanager/intern/wm_files.c
+ * \ingroup wm
+ */
+
+
/* placed up here because of crappy
* winsock stuff.
*/
@@ -257,6 +262,10 @@ static void wm_init_userdef(bContext *C)
MEM_CacheLimiter_set_maximum(U.memcachelimit * 1024 * 1024);
sound_init(CTX_data_main(C));
+ /* needed so loading a file from the command line respects user-pref [#26156] */
+ if(U.flag & USER_FILENOUI) G.fileflags |= G_FILE_NO_UI;
+ else G.fileflags &= ~G_FILE_NO_UI;
+
/* set the python auto-execute setting from user prefs */
/* disabled by default, unless explicitly enabled in the command line */
if ((U.flag & USER_SCRIPT_AUTOEXEC_DISABLE) == 0) G.f |= G_SCRIPT_AUTOEXEC;
@@ -424,7 +433,7 @@ int WM_read_homefile(bContext *C, ReportList *reports, short from_memory)
#ifdef WITH_PYTHON
if(CTX_py_init_get(C)) {
/* sync addons, these may have changed from the defaults */
- BPY_string_exec(C, "__import__('bpy').utils.addon_reset_all()");
+ BPY_string_exec(C, "__import__('addon_utils').reset_all()");
BPY_driver_reset();
BPY_modules_load_user(C);