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:
Diffstat (limited to 'source/blender/python/api2_2x/MTex.c')
-rw-r--r--source/blender/python/api2_2x/MTex.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/python/api2_2x/MTex.c b/source/blender/python/api2_2x/MTex.c
index b9a8f7fff65..a95836f0596 100644
--- a/source/blender/python/api2_2x/MTex.c
+++ b/source/blender/python/api2_2x/MTex.c
@@ -677,7 +677,7 @@ static int MTex_setMapping( BPy_MTex *self, PyObject *value, void *closure)
static PyObject *MTex_getFlag( BPy_MTex *self, void *closure )
{
- return PyBool_FromLong( self->mtex->texflag & ((int) closure) );
+ return PyBool_FromLong( self->mtex->texflag & (GET_INT_FROM_POINTER(closure)) );
}
static int MTex_setFlag( BPy_MTex *self, PyObject *value, void *closure)
@@ -687,9 +687,9 @@ static int MTex_setFlag( BPy_MTex *self, PyObject *value, void *closure)
"expected a bool");
if ( value == Py_True )
- self->mtex->texflag |= (int)closure;
+ self->mtex->texflag |= GET_INT_FROM_POINTER(closure);
else
- self->mtex->texflag &= ~((int) closure);
+ self->mtex->texflag &= ~(GET_INT_FROM_POINTER(closure));
return 0;
}
@@ -774,7 +774,7 @@ static int MTex_setProjZ( BPy_MTex *self, PyObject *value, void *closure)
static PyObject *MTex_getMapToFlag( BPy_MTex *self, void *closure )
{
- int flag = (int) closure;
+ int flag = GET_INT_FROM_POINTER(closure);
if ( self->mtex->mapto & flag )
{
@@ -786,7 +786,7 @@ static PyObject *MTex_getMapToFlag( BPy_MTex *self, void *closure )
static int MTex_setMapToFlag( BPy_MTex *self, PyObject *value, void *closure)
{
- int flag = (int) closure;
+ int flag = GET_INT_FROM_POINTER(closure);
int intVal;
if ( !PyInt_Check( value ) )