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/Draw.c')
-rw-r--r--source/blender/python/api2_2x/Draw.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/source/blender/python/api2_2x/Draw.c b/source/blender/python/api2_2x/Draw.c
index f6c5aff0db8..ec72394efc2 100644
--- a/source/blender/python/api2_2x/Draw.c
+++ b/source/blender/python/api2_2x/Draw.c
@@ -850,6 +850,8 @@ static PyObject *Method_Toggle( PyObject * self, PyObject * args )
static void py_slider_update( void *butv, void *data2_unused )
{
uiBut *but = butv;
+ PyObject *ref = Py_BuildValue( "(i)", SPACE_VIEW3D );
+ PyObject *ret = NULL;
EXPP_disable_force_draw = 1;
/*@ Disable forced drawing, otherwise the button object which
@@ -862,8 +864,12 @@ static void py_slider_update( void *butv, void *data2_unused )
spacescript_do_pywin_buttons( curarea->spacedata.first,
uiButGetRetVal( but ) );
- /* XXX useless right now: */
- M_Window_Redraw( 0, Py_BuildValue( "(i)", SPACE_VIEW3D ) );
+
+ /* XXX useless right now, investigate better before a bcon 5 */
+ ret = M_Window_Redraw( 0, ref );
+
+ Py_DECREF(ref);
+ if (ret) { Py_DECREF(ret); }
disable_where_script( 0 );