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:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2011-09-28 23:05:47 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2011-09-28 23:05:47 +0400
commita52ac47305e641030695221e2ead8b239b1a531c (patch)
treeee8b51883dc3eff409f2ea82817f6d7c4aef57e8 /source/blender/windowmanager
parent2ad45b5c4f54765ad8804d26dd28b1eca2c235e5 (diff)
Fix #28726: maya key configuration lost after file > new.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r--source/blender/windowmanager/intern/wm_files.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c
index f862af6173a..c08b8c0d01f 100644
--- a/source/blender/windowmanager/intern/wm_files.c
+++ b/source/blender/windowmanager/intern/wm_files.c
@@ -226,13 +226,16 @@ static void wm_window_match_do(bContext *C, ListBase *oldwmlist)
oldwm= oldwmlist->first;
wm= G.main->wm.first;
- /* move addon key configuration to new wm, to preserve their keymaps */
- if(oldwm->addonconf) {
- wm->addonconf= oldwm->addonconf;
- BLI_remlink(&oldwm->keyconfigs, oldwm->addonconf);
- oldwm->addonconf= NULL;
- BLI_addtail(&wm->keyconfigs, wm->addonconf);
- }
+ /* preserve key configurations in new wm, to preserve their keymaps */
+ wm->keyconfigs= oldwm->keyconfigs;
+ wm->addonconf= oldwm->addonconf;
+ wm->defaultconf= oldwm->defaultconf;
+ wm->userconf= oldwm->userconf;
+
+ oldwm->keyconfigs.first= oldwm->keyconfigs.last= NULL;
+ oldwm->addonconf= NULL;
+ oldwm->defaultconf= NULL;
+ oldwm->userconf= NULL;
/* ensure making new keymaps and set space types */
wm->initialized= 0;