A little housekeeping:
Object.c - expand evil 1 character name. nicer error msg. doc/Object.py - clarify Object.getData() doc
This commit is contained in:
@@ -119,7 +119,7 @@ static PyObject *Object_buildParts( BPy_Object * self );
|
||||
static PyObject *Object_clearIpo( BPy_Object * self );
|
||||
static PyObject *Object_clrParent( BPy_Object * self, PyObject * args );
|
||||
static PyObject *Object_clearTrack( BPy_Object * self, PyObject * args );
|
||||
static PyObject *Object_getData(BPy_Object *self, PyObject *a, PyObject *kwd);
|
||||
static PyObject *Object_getData(BPy_Object *self, PyObject *args, PyObject *kwd);
|
||||
static PyObject *Object_getDeltaLocation( BPy_Object * self );
|
||||
static PyObject *Object_getDrawMode( BPy_Object * self );
|
||||
static PyObject *Object_getDrawType( BPy_Object * self );
|
||||
@@ -764,16 +764,16 @@ int EXPP_add_obdata( struct Object *object )
|
||||
}
|
||||
|
||||
|
||||
static PyObject *Object_getData( BPy_Object *self, PyObject *a, PyObject *kwd )
|
||||
static PyObject *Object_getData( BPy_Object *self, PyObject *args, PyObject *kwd )
|
||||
{
|
||||
PyObject *data_object;
|
||||
Object *object = self->object;
|
||||
int name_only = 0;
|
||||
static char *kwlist[] = {"name_only", NULL};
|
||||
|
||||
if (!PyArg_ParseTupleAndKeywords(a, kwd, "|i", kwlist, &name_only))
|
||||
if (!PyArg_ParseTupleAndKeywords(args, kwd, "|i", kwlist, &name_only))
|
||||
return EXPP_ReturnPyObjError( PyExc_AttributeError,
|
||||
"expected nothing or an int (keyword 'name_only') as argument" );
|
||||
"expected nothing or bool keyword 'name_only' as argument" );
|
||||
|
||||
/* if there's no obdata, try to create it */
|
||||
if( object->data == NULL ) {
|
||||
|
||||
@@ -188,14 +188,11 @@ class Object:
|
||||
|
||||
def getData(name_only = False):
|
||||
"""
|
||||
Returns the Datablock object (new: or just its name) containing the
|
||||
object's data. For example the Mesh, Lamp or the Camera.
|
||||
Returns the Datablock object (Mesh, Lamp, Camera, etc.) linked to this Object. If the keyword parameter 'name_only' is True, only the Datablock name is returned as a string.
|
||||
@type name_only: bool
|
||||
@param name_only: if True on nonzero, only the name of the data object
|
||||
is returned.
|
||||
@rtype: Object type specific or string
|
||||
@return: Depending on the type of the Object, it returns a specific object
|
||||
for the data requested. If name_only is True, it returns a string.
|
||||
@param name_only: This is a keyword parameter. if True (or nonzero), only the name of the data object is returned. The default value is False.
|
||||
@rtype: specific Object type or string
|
||||
@return: Depends on the type of Datablock linked to the Object. If name_only is True, it returns a string.
|
||||
"""
|
||||
|
||||
def getDeltaLocation():
|
||||
|
||||
Reference in New Issue
Block a user