[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [26852] trunk/blender/source/blender/ python/intern/bpy_operator.c: Calling operators from Python with non-default context was broken ( need to assign to the right variable).

Martin Poirier theeth at yahoo.com
Fri Feb 12 22:40:46 CET 2010


Revision: 26852
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=26852
Author:   theeth
Date:     2010-02-12 22:40:46 +0100 (Fri, 12 Feb 2010)

Log Message:
-----------
Calling operators from Python with non-default context was broken (need to assign to the right variable).

Modified Paths:
--------------
    trunk/blender/source/blender/python/intern/bpy_operator.c

Modified: trunk/blender/source/blender/python/intern/bpy_operator.c
===================================================================
--- trunk/blender/source/blender/python/intern/bpy_operator.c	2010-02-12 21:14:01 UTC (rev 26851)
+++ trunk/blender/source/blender/python/intern/bpy_operator.c	2010-02-12 21:40:46 UTC (rev 26852)
@@ -72,7 +72,7 @@
 	}
 	
 	if(context_str) {
-		if(RNA_enum_value_from_id(operator_context_items, context_str, &operator_ret)==0) {
+		if(RNA_enum_value_from_id(operator_context_items, context_str, &context)==0) {
 			char *enum_str= BPy_enum_as_string(operator_context_items);
 			PyErr_Format(PyExc_TypeError, "Calling operator \"bpy.ops.%s\" error, expected a string enum in (%.200s)", opname, enum_str);
 			MEM_freeN(enum_str);





More information about the Bf-blender-cvs mailing list