From 51ae88aa3b84565d79ab8819807f90aa3844479a Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Wed, 8 Jul 2009 21:31:28 +0000 Subject: 2.5: Mesh and Various Fixes * 3D view Mesh menu works again, but incomplete. * Add Properties and Toolbar to 3D View menu. * Added "specials" menus back, vertex/edge/face and general. * Various fixes in existing mesh operators, some were not working. * Add MESH_OT_merge. * Merge all subdivide ops into MESH_OT_subdivide, subdivide code changes to make smooth + multi give good results. * Rename all select inverse ops to *_OT_select_inverse. * Fix "search for unknown operator" prints at startup, and some warnings in py code. * Don't run .pyc files on startup. * Remove unused image window header C code. --- source/blender/python/intern/bpy_operator_wrap.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'source/blender/python/intern/bpy_operator_wrap.c') diff --git a/source/blender/python/intern/bpy_operator_wrap.c b/source/blender/python/intern/bpy_operator_wrap.c index 60a9afda0c4..f8567414717 100644 --- a/source/blender/python/intern/bpy_operator_wrap.c +++ b/source/blender/python/intern/bpy_operator_wrap.c @@ -352,9 +352,10 @@ PyObject *PYOP_wrap_add(PyObject *self, PyObject *py_class) idname = _PyUnicode_AsString(item); /* remove if it already exists */ - if ((ot=WM_operatortype_find(idname))) { - if(ot->pyop_data) + if ((ot=WM_operatortype_exists(idname))) { + if(ot->pyop_data) { Py_XDECREF((PyObject*)ot->pyop_data); + } WM_operatortype_remove(idname); } @@ -402,7 +403,7 @@ PyObject *PYOP_wrap_remove(PyObject *self, PyObject *value) return NULL; } - if (!(ot= WM_operatortype_find(idname))) { + if (!(ot= WM_operatortype_exists(idname))) { PyErr_Format( PyExc_AttributeError, "Operator \"%s\" does not exists, cant remove", idname); return NULL; } -- cgit v1.2.3