Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWillian Padovani Germano <wpgermano@gmail.com>2005-01-13 06:04:12 +0300
committerWillian Padovani Germano <wpgermano@gmail.com>2005-01-13 06:04:12 +0300
commit9f43accdb2319b567551f652a6966a5fa56f086b (patch)
treec19431b0a9cbed1ffa6af17b020705c59f766efc /source/blender/python/api2_2x/Image.c
parent5161998bbe2c76df281a920e96523298e5e8baa6 (diff)
BPython:
- patch by Jonathan Merritt: new function Blender.Draw.Image() + its doc; - patch by Campbell Barton: .users attribute for many types; - tiny internal change in nmesh.hasVertexUV() method. Thanks to Jonathan and Campbell for the patches and the patience!
Diffstat (limited to 'source/blender/python/api2_2x/Image.c')
-rw-r--r--source/blender/python/api2_2x/Image.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/source/blender/python/api2_2x/Image.c b/source/blender/python/api2_2x/Image.c
index ce70db0cf75..a27cba7d2a2 100644
--- a/source/blender/python/api2_2x/Image.c
+++ b/source/blender/python/api2_2x/Image.c
@@ -606,11 +606,12 @@ static PyObject *Image_getAttr( BPy_Image * self, char *name )
attr = PyInt_FromLong( self->image->yrep );
else if( strcmp( name, "bindcode" ) == 0 )
attr = PyInt_FromLong( self->image->bindcode );
-
+ else if( strcmp( name, "users" ) == 0 )
+ attr = PyInt_FromLong( self->image->id.us );
else if( strcmp( name, "__members__" ) == 0 )
- attr = Py_BuildValue( "[s,s,s,s,s,s,s]",
+ attr = Py_BuildValue( "[s,s,s,s,s,s,s,s]",
"name", "filename", "size", "depth",
- "xrep", "yrep", "bindcode" );
+ "xrep", "yrep", "bindcode", "users" );
if( !attr )
return ( EXPP_ReturnPyObjError( PyExc_MemoryError,