[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [51154] branches/ge_components/source/ blender/blenkernel/intern/python_component.c: Removing some unused code from python_component.c.

Mitchell Stokes mogurijin at gmail.com
Mon Oct 8 02:06:11 CEST 2012


Revision: 51154
          http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=51154
Author:   moguri
Date:     2012-10-08 00:06:10 +0000 (Mon, 08 Oct 2012)
Log Message:
-----------
Removing some unused code from python_component.c.

Modified Paths:
--------------
    branches/ge_components/source/blender/blenkernel/intern/python_component.c

Modified: branches/ge_components/source/blender/blenkernel/intern/python_component.c
===================================================================
--- branches/ge_components/source/blender/blenkernel/intern/python_component.c	2012-10-07 23:58:57 UTC (rev 51153)
+++ branches/ge_components/source/blender/blenkernel/intern/python_component.c	2012-10-08 00:06:10 UTC (rev 51154)
@@ -124,34 +124,6 @@
 	return pyclass;
 }
 
-static PyObject *arg_dict_from_component(PythonComponent *pc)
-{
-	ComponentProperty *cprop;
-	PyObject *args= NULL, *value=NULL;
-
-	args = PyDict_New();
-
-	cprop = pc->properties.first;
-
-	while (cprop) {
-		if (cprop->type == CPROP_TYPE_INT)
-			value = PyLong_FromLong(cprop->data);
-		else if (cprop->type == CPROP_TYPE_FLOAT)
-			value = PyFloat_FromDouble(*(float*)(&cprop->data));
-		else if (cprop->type == CPROP_TYPE_BOOLEAN)
-			value = PyBool_FromLong(cprop->data);
-		else if (cprop->type == CPROP_TYPE_STRING)
-			value = PyUnicode_FromString((char*)cprop->poin);
-		else
-			continue;
-
-		PyDict_SetItemString(args, cprop->name, value);
-
-		cprop= cprop->next;
-	}
-
-	return args;
-}
 #endif /* WITH_PYTHON */
 
 static ComponentProperty *create_property(char *name, short type, int data, void *poin)




More information about the Bf-blender-cvs mailing list