removed duplicate functionality, macro's and functions existed to check a PyObjects type, now only use macro's

This commit is contained in:
2007-03-15 01:09:14 +00:00
parent a567e43628
commit ee5dc4d0bf
66 changed files with 54 additions and 319 deletions

View File

@@ -531,7 +531,7 @@ static int action_setter( BPy_Constraint *self, int type, PyObject *value )
}
case EXPP_CONSTR_ACTION: {
bAction *act = (( BPy_Action * )value)->action;
if( !Action_CheckPyObject( value ) )
if( !BPy_Action_Check( value ) )
return EXPP_ReturnIntError( PyExc_TypeError,
"expected BPy action argument" );
con->act = act;
@@ -1481,16 +1481,6 @@ PyObject *Constraint_CreatePyObject( bPoseChannel *pchan, Object *obj,
return ( PyObject * ) pycon;
}
/*****************************************************************************/
/* Function: Constraint_CheckPyObject */
/* Description: This function returns true when the given PyObject is of the */
/* type Constraint. Otherwise it will return false. */
/*****************************************************************************/
int Constraint_CheckPyObject( PyObject * pyobj )
{
return ( pyobj->ob_type == &Constraint_Type );
}
/*****************************************************************************/
/* Function: Constraint_FromPyObject */
/* Description: This function returns the Blender constraint from the given */