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:
authorCampbell Barton <ideasman42@gmail.com>2013-11-26 01:59:14 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-11-26 02:00:24 +0400
commit02f90c000115d5d2ab330005e20d02419defe35a (patch)
tree932763725edb3642e3e3da0905e02676f42a54e8 /source/blender/python/intern/bpy_operator.c
parent07bde9e797c73a0cdbeef315755874ff711a6414 (diff)
User Interface: don't show macro args in tooltips
was often making much too big strings to show in a tip.
Diffstat (limited to 'source/blender/python/intern/bpy_operator.c')
-rw-r--r--source/blender/python/intern/bpy_operator.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/python/intern/bpy_operator.c b/source/blender/python/intern/bpy_operator.c
index 754952cd65f..e867aa00958 100644
--- a/source/blender/python/intern/bpy_operator.c
+++ b/source/blender/python/intern/bpy_operator.c
@@ -313,6 +313,7 @@ static PyObject *pyop_as_string(PyObject *UNUSED(self), PyObject *args)
char *opname;
PyObject *kw = NULL; /* optional args */
int all_args = 1;
+ int macro_args = 1;
int error_val = 0;
char *buf = NULL;
@@ -325,7 +326,7 @@ static PyObject *pyop_as_string(PyObject *UNUSED(self), PyObject *args)
return NULL;
}
- if (!PyArg_ParseTuple(args, "s|O!i:_bpy.ops.as_string", &opname, &PyDict_Type, &kw, &all_args))
+ if (!PyArg_ParseTuple(args, "s|O!ii:_bpy.ops.as_string", &opname, &PyDict_Type, &kw, &all_args, &macro_args))
return NULL;
ot = WM_operatortype_find(opname, true);
@@ -345,7 +346,7 @@ static PyObject *pyop_as_string(PyObject *UNUSED(self), PyObject *args)
error_val = pyrna_pydict_to_props(&ptr, kw, 0, "Converting py args to operator properties: ");
if (error_val == 0)
- buf = WM_operator_pystring_ex(C, NULL, all_args, ot, &ptr);
+ buf = WM_operator_pystring_ex(C, NULL, all_args, macro_args, ot, &ptr);
WM_operator_properties_free(&ptr);