Cleanup: reorder report argument for pointer assignment

Most code uses ReportList argument last (or at least not first)
when an optional report list can be passed in.
This commit is contained in:
2019-05-20 18:06:09 +10:00
parent 88d2d82031
commit d00c54c855
49 changed files with 287 additions and 287 deletions

View File

@@ -2775,7 +2775,7 @@ bool ui_but_string_set(bContext *C, uiBut *but, const char *str)
}
else if (type == PROP_POINTER) {
if (str[0] == '\0') {
RNA_property_pointer_set(NULL, &but->rnapoin, but->rnaprop, PointerRNA_NULL);
RNA_property_pointer_set(&but->rnapoin, but->rnaprop, PointerRNA_NULL, NULL);
return true;
}
else {
@@ -2791,14 +2791,14 @@ bool ui_but_string_set(bContext *C, uiBut *but, const char *str)
* Fact remains, using editstr as main 'reference' over whole search button thingy
* is utterly weak and should be redesigned imho, but that's not a simple task. */
if (prop && RNA_property_collection_lookup_string(&ptr, prop, str, &rptr)) {
RNA_property_pointer_set(NULL, &but->rnapoin, but->rnaprop, rptr);
RNA_property_pointer_set(&but->rnapoin, but->rnaprop, rptr, NULL);
}
else if (but->func_arg2 != NULL) {
RNA_pointer_create(NULL,
RNA_property_pointer_type(&but->rnapoin, but->rnaprop),
but->func_arg2,
&rptr);
RNA_property_pointer_set(NULL, &but->rnapoin, but->rnaprop, rptr);
RNA_property_pointer_set(&but->rnapoin, but->rnaprop, rptr, NULL);
}
return true;