diff options
author | Martin Poirier <theeth@yahoo.com> | 2009-12-05 22:05:21 +0300 |
---|---|---|
committer | Martin Poirier <theeth@yahoo.com> | 2009-12-05 22:05:21 +0300 |
commit | f287762678d8c55fc2495e7a0ffe71c3ee3006b1 (patch) | |
tree | fd8c6f7f973575363cb26d6b1bba21ea68eb0836 /source | |
parent | d98cbf7727ccad91545882be4ac4ee4c044fc726 (diff) |
Macros in macro didn't work correctly.
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/windowmanager/intern/wm_event_system.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c index 93c8b669611..c19d1000573 100644 --- a/source/blender/windowmanager/intern/wm_event_system.c +++ b/source/blender/windowmanager/intern/wm_event_system.c @@ -382,10 +382,13 @@ static wmOperator *wm_operator_create(wmWindowManager *wm, wmOperatorType *ot, P if(ot->macro.first) { static wmOperator *motherop= NULL; wmOperatorTypeMacro *otmacro; + int root = 0; /* ensure all ops are in execution order in 1 list */ - if(motherop==NULL) - motherop= op; + if(motherop==NULL) { + motherop = op; + root = 1; + } for(otmacro= ot->macro.first; otmacro; otmacro= otmacro->next) { wmOperatorType *otm= WM_operatortype_find(otmacro->idname, 0); @@ -395,7 +398,8 @@ static wmOperator *wm_operator_create(wmWindowManager *wm, wmOperatorType *ot, P opm->opm= motherop; /* pointer to mom, for modal() */ } - motherop= NULL; + if (root) + motherop= NULL; } return op; |