[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [25138] trunk/blender/source/blender/ windowmanager/intern/wm_event_system.c: Macros in macro didn' t work correctly.

Martin Poirier theeth at yahoo.com
Sat Dec 5 20:05:21 CET 2009


Revision: 25138
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=25138
Author:   theeth
Date:     2009-12-05 20:05:21 +0100 (Sat, 05 Dec 2009)

Log Message:
-----------
Macros in macro didn't work correctly.

Modified Paths:
--------------
    trunk/blender/source/blender/windowmanager/intern/wm_event_system.c

Modified: trunk/blender/source/blender/windowmanager/intern/wm_event_system.c
===================================================================
--- trunk/blender/source/blender/windowmanager/intern/wm_event_system.c	2009-12-05 14:12:06 UTC (rev 25137)
+++ trunk/blender/source/blender/windowmanager/intern/wm_event_system.c	2009-12-05 19:05:21 UTC (rev 25138)
@@ -382,10 +382,13 @@
 	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 @@
 			opm->opm= motherop; /* pointer to mom, for modal() */
 		}
 		
-		motherop= NULL;
+		if (root)
+			motherop= NULL;
 	}
 	
 	return op;





More information about the Bf-blender-cvs mailing list