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:
authorCampbell Barton <ideasman42@gmail.com>2021-03-14 10:00:15 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-03-14 10:00:15 +0300
commitd2f4fc8275d4df6e585815757c69c762412bfa65 (patch)
tree2ddcd1123721cb39268a7cdc512dc604336b0655 /source/blender/windowmanager/intern/wm.c
parent15d728531a333da6bbe921b0f200684cbac3eac0 (diff)
WM: support loading keymaps in background mode
While this still isn't done by default on startup, activating a key-config will load it as expected. Needed to perform key-map loading tests in background mode.
Diffstat (limited to 'source/blender/windowmanager/intern/wm.c')
-rw-r--r--source/blender/windowmanager/intern/wm.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/windowmanager/intern/wm.c b/source/blender/windowmanager/intern/wm.c
index b66544831f1..3f1bbb7a669 100644
--- a/source/blender/windowmanager/intern/wm.c
+++ b/source/blender/windowmanager/intern/wm.c
@@ -473,7 +473,10 @@ void WM_keyconfig_init(bContext *C)
wm->defaultconf->flag |= KEYCONF_INIT_DEFAULT;
}
- WM_keyconfig_update_tag(NULL, NULL);
+ /* Harmless, but no need to update in background mode. */
+ if (!G.background) {
+ WM_keyconfig_update_tag(NULL, NULL);
+ }
WM_keyconfig_update(wm);
wm->initialized |= WM_KEYCONFIG_IS_INIT;