diff options
Diffstat (limited to 'source/blender/python/intern/bpy_app.c')
-rw-r--r-- | source/blender/python/intern/bpy_app.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/source/blender/python/intern/bpy_app.c b/source/blender/python/intern/bpy_app.c index 6c4e190673c..46a3c93292b 100644 --- a/source/blender/python/intern/bpy_app.c +++ b/source/blender/python/intern/bpy_app.c @@ -26,6 +26,7 @@ #include "BLI_path_util.h" +#include "BKE_utildefines.h" #include "BKE_blender.h" #include "BKE_global.h" #include "structseq.h" @@ -116,21 +117,15 @@ static PyObject *make_app_info(void) /* a few getsets because it makes sense for them to be in bpy.app even though * they are not static */ -static PyObject *bpy_app_debug_get(PyObject *self, void *closure) +static PyObject *bpy_app_debug_get(PyObject *UNUSED(self), void *UNUSED(closure)) { - (void)(self); - (void)(closure); - return PyBool_FromLong(G.f & G_DEBUG); } -static int bpy_app_debug_set(PyObject *self, PyObject *value, void *closure) +static int bpy_app_debug_set(PyObject *UNUSED(self), PyObject *value, void *UNUSED(closure)) { int param= PyObject_IsTrue(value); - (void)(self); - (void)(closure); - if(param < 0) { PyErr_SetString(PyExc_TypeError, "bpy.app.debug can only be True/False"); return -1; @@ -142,12 +137,9 @@ static int bpy_app_debug_set(PyObject *self, PyObject *value, void *closure) return 0; } -static PyObject *bpy_app_tempdir_get(PyObject *self, void *closure) +static PyObject *bpy_app_tempdir_get(PyObject *UNUSED(self), void *UNUSED(closure)) { extern char btempdir[]; - (void)(self); - (void)(closure); - return PyC_UnicodeFromByte(btempdir); } |