diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-04-28 19:14:16 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-04-28 19:14:16 +0400 |
commit | ef054e165cad35715a5b2388aac3db68a65ea275 (patch) | |
tree | 0726e9c5a28962839a8d36ba4647f0b76fff7ad2 /source/blender/python/intern | |
parent | 887d1533f81b0ee89975efd8162a011b99c976af (diff) |
style cleanup: format 'for' loop macros the same as for loops, some renaming to BLI_array macros.
Diffstat (limited to 'source/blender/python/intern')
-rw-r--r-- | source/blender/python/intern/bpy_rna.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/python/intern/bpy_rna.c b/source/blender/python/intern/bpy_rna.c index 7259ea8e2f5..7c8f28d0979 100644 --- a/source/blender/python/intern/bpy_rna.c +++ b/source/blender/python/intern/bpy_rna.c @@ -1424,7 +1424,7 @@ int pyrna_pydict_to_props(PointerRNA *ptr, PyObject *kw, int all_args, const cha totkw = kw ? PyDict_Size(kw) : 0; - RNA_STRUCT_BEGIN(ptr, prop) { + RNA_STRUCT_BEGIN (ptr, prop) { arg_name = RNA_property_identifier(prop); if (strcmp(arg_name, "rna_type") == 0) continue; @@ -2203,7 +2203,7 @@ int pyrna_prop_collection_subscript_str_lib_pair_ptr(BPy_PropertyRNA *self, PyOb /* lib is either a valid poniter or NULL, * either way can do direct comparison with id.lib */ - RNA_PROP_BEGIN(&self->ptr, itemptr, self->prop) { + RNA_PROP_BEGIN (&self->ptr, itemptr, self->prop) { ID *id = itemptr.data; /* always an ID */ if (id->lib == lib && (strncmp(keyname, id->name + 2, sizeof(id->name) - 2) == 0)) { found = TRUE; @@ -3346,7 +3346,7 @@ static void pyrna_dir_members_rna(PyObject *list, PointerRNA *ptr) RNA_pointer_create(NULL, &RNA_Struct, ptr->type, &tptr); iterprop = RNA_struct_find_property(&tptr, "functions"); - RNA_PROP_BEGIN(&tptr, itemptr, iterprop) { + RNA_PROP_BEGIN (&tptr, itemptr, iterprop) { idname = RNA_function_identifier(itemptr.data); pystring = PyUnicode_FromString(idname); @@ -3365,7 +3365,7 @@ static void pyrna_dir_members_rna(PyObject *list, PointerRNA *ptr) iterprop = RNA_struct_iterator_property(ptr->type); - RNA_PROP_BEGIN(ptr, itemptr, iterprop) { + RNA_PROP_BEGIN (ptr, itemptr, iterprop) { nameptr = RNA_struct_name_get_alloc(&itemptr, name, sizeof(name), &namelen); if (nameptr) { @@ -3980,7 +3980,7 @@ static PyObject *pyrna_prop_collection_keys(BPy_PropertyRNA *self) char name[256], *nameptr; int namelen; - RNA_PROP_BEGIN(&self->ptr, itemptr, self->prop) { + RNA_PROP_BEGIN (&self->ptr, itemptr, self->prop) { nameptr = RNA_struct_name_get_alloc(&itemptr, name, sizeof(name), &namelen); if (nameptr) { @@ -4017,7 +4017,7 @@ static PyObject *pyrna_prop_collection_items(BPy_PropertyRNA *self) int namelen; int i = 0; - RNA_PROP_BEGIN(&self->ptr, itemptr, self->prop) { + RNA_PROP_BEGIN (&self->ptr, itemptr, self->prop) { if (itemptr.data) { /* add to python list */ item = PyTuple_New(2); @@ -4189,7 +4189,7 @@ static PyObject *pyrna_prop_collection_find(BPy_PropertyRNA *self, PyObject *key PYRNA_PROP_CHECK_OBJ(self); - RNA_PROP_BEGIN(&self->ptr, itemptr, self->prop) { + RNA_PROP_BEGIN (&self->ptr, itemptr, self->prop) { nameptr = RNA_struct_name_get_alloc(&itemptr, name, sizeof(name), &namelen); if (nameptr) { @@ -4220,7 +4220,7 @@ static void foreach_attr_type(BPy_PropertyRNA *self, const char *attr, *attr_signed = FALSE; /* note: this is fail with zero length lists, so don't let this get caled in that case */ - RNA_PROP_BEGIN(&self->ptr, itemptr, self->prop) { + RNA_PROP_BEGIN (&self->ptr, itemptr, self->prop) { prop = RNA_struct_find_property(&itemptr, attr); *raw_type = RNA_property_raw_type(prop); *attr_tot = RNA_property_array_length(&itemptr, prop); @@ -6401,7 +6401,7 @@ static PyObject *pyrna_basetype_dir(BPy_BaseTypeRNA *self) PyObject *ret = PyList_New(0); PyObject *item; - RNA_PROP_BEGIN(&self->ptr, itemptr, self->prop) { + RNA_PROP_BEGIN (&self->ptr, itemptr, self->prop) { StructRNA *srna = itemptr.data; StructRNA *srna_base = RNA_struct_base(itemptr.data); /* skip own operators, these double up [#29666] */ @@ -7189,7 +7189,7 @@ void pyrna_alloc_types(void) RNA_blender_rna_pointer_create(&ptr); prop = RNA_struct_find_property(&ptr, "structs"); - RNA_PROP_BEGIN(&ptr, itemptr, prop) { + RNA_PROP_BEGIN (&ptr, itemptr, prop) { PyObject *item = pyrna_struct_Subtype(&itemptr); if (item == NULL) { if (PyErr_Occurred()) { @@ -7217,7 +7217,7 @@ void pyrna_free_types(void) prop = RNA_struct_find_property(&ptr, "structs"); - RNA_PROP_BEGIN(&ptr, itemptr, prop) { + RNA_PROP_BEGIN (&ptr, itemptr, prop) { StructRNA *srna = srna_from_ptr(&itemptr); void *py_ptr = RNA_struct_py_type_get(srna); @@ -7477,7 +7477,7 @@ static PyObject *pyrna_unregister_class(PyObject *UNUSED(self), PyObject *py_cla /* loop over all structs */ - RNA_PROP_BEGIN(&ptr_rna, itemptr, prop_rna) { + RNA_PROP_BEGIN (&ptr_rna, itemptr, prop_rna) { srna_iter = itemptr.data; if (pyrna_srna_contains_pointer_prop_srna(srna_iter, srna, &prop_identifier)) { break; |