- Fix related to bug #2157: crash in Blender.Image.image.reload() method.  "G.sima" was not being checked for validity.  Fix by Joilnen B. Leite (pidhash).  Thanks!
http://projects.blender.org/tracker/?func=detail&atid=125&aid=2157&group_id=9
- Added optional argument to Blender.Object.object.getData() method: getData(only_name = True) or (only_name = 1) or (1) will return only the obdata name, not a wrapper for the given struct.  This is a test based on a request by Campbell Barton who submitted code for his proposed .getDataName() method (thanks!).
- doc updates and small fixes.
This commit is contained in:
2005-02-02 03:38:31 +00:00
parent 78f133b8a7
commit 41b251fab0
4 changed files with 48 additions and 22 deletions

View File

@@ -3,8 +3,8 @@
"""
The Blender.Object submodule
B{New}: 'old_worldspace' parameter in L{Object.Object.getMatrix}, which now
defaults to 'worldspace'.
B{New}: L{Object.getData} now accepts an optional bool keyword argument to
define if the user wants the data object or just its name.
Object
======
@@ -186,13 +186,16 @@ class Object:
other value, or no value at all will update the scene hierarchy.
"""
def getData():
def getData(only_name = False):
"""
Returns the Datablock object containing the object's data. For example the
Mesh, Lamp or the Camera.
@rtype: Object type specific
Returns the Datablock object (new: or just its name) containing the
object's data. For example the Mesh, Lamp or the Camera.
@type only_name: bool
@param only_name: 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.
for the data requested. If only_name is True, it returns a string.
"""
def getDeltaLocation():