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:
authorKen Hughes <khughes@pacific.edu>2007-03-31 19:31:37 +0400
committerKen Hughes <khughes@pacific.edu>2007-03-31 19:31:37 +0400
commitbf8bb77abc3f48ab808d76863c653856a9a08507 (patch)
treeaa56abc4d066c5f9fa19e1e70858cdbc0d7f3dae /source/blender/python/api2_2x/Image.c
parent417498a86532b3b4c228727c516c5052ef6c8227 (diff)
Python API
---------- Change deprecation printfs to print warning once instead of everytime the deprecated method is called. Also commented out deprecation warnings for code which will eventually be replaced by experimental Blender.Main/bpy module.
Diffstat (limited to 'source/blender/python/api2_2x/Image.c')
-rw-r--r--source/blender/python/api2_2x/Image.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/source/blender/python/api2_2x/Image.c b/source/blender/python/api2_2x/Image.c
index fed54aaed5b..06a9c8db1de 100644
--- a/source/blender/python/api2_2x/Image.c
+++ b/source/blender/python/api2_2x/Image.c
@@ -689,7 +689,13 @@ static PyObject *Image_pack( BPy_Image * self )
static PyObject *Image_makeCurrent( BPy_Image * self )
{
- printf("deprecated! use Blender.Main.images.active = image instead\n");
+#if 0 /* add back in when bpy becomes "official" */
+ static char warning = 1;
+ if( warning ) {
+ printf("image.makeCurrent() deprecated!\n\t use 'bpy.images.active = image instead'\n");
+ --warning;
+ }
+#endif
if (!G.sima)
Py_RETURN_FALSE;