From c0f567e757cab55c1ed77d44a204c21023422859 Mon Sep 17 00:00:00 2001 From: Maxime Curioni Date: Fri, 25 Jul 2008 01:38:19 +0000 Subject: soc-2008-mxcurioni: fully implemented (but did not test) ViewEdge class. Modified functions accross API taking input boolean values. --- source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp') diff --git a/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp b/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp index 24c0263bc5f..541ef4f4516 100644 --- a/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp +++ b/source/blender/freestyle/intern/python/BPy_StrokeAttribute.cpp @@ -395,17 +395,19 @@ PyObject * StrokeAttribute_setThickness( BPy_StrokeAttribute *self, PyObject *ar } PyObject * StrokeAttribute_setVisible( BPy_StrokeAttribute *self, PyObject *args ) { - int i = 0; + PyObject *py_b; - if(!( PyArg_ParseTuple(args, "i", &i) )) { + if(!( PyArg_ParseTuple(args, "O", &py_b) && PyBool_Check(py_b) )) { cout << "ERROR: StrokeAttribute_setVisible" << endl; Py_RETURN_NONE; } - self->sa->setVisible( i ); + self->sa->setVisible( bool_from_PyBool(py_b) ); + Py_RETURN_NONE; } + PyObject * StrokeAttribute_setAttributeReal( BPy_StrokeAttribute *self, PyObject *args ) { char *s = 0; double d = 0; -- cgit v1.2.3