Commit: 4fc1510dd8f2cac70ac4e0e813c82a88fe462e15
Author: Campbell Barton
Date:   Fri Jun 24 10:05:09 2016 +1000
Branches: master
https://developer.blender.org/rB4fc1510dd8f2cac70ac4e0e813c82a88fe462e15

Cleanup: use return argument prefix

===================================================================

M       source/blender/editors/include/UI_interface.h
M       source/blender/editors/interface/interface_handlers.c
M       source/blender/editors/interface/interface_templates.c

===================================================================

diff --git a/source/blender/editors/include/UI_interface.h 
b/source/blender/editors/include/UI_interface.h
index 9aad340..a623f5c 100644
--- a/source/blender/editors/include/UI_interface.h
+++ b/source/blender/editors/include/UI_interface.h
@@ -1020,12 +1020,18 @@ bool UI_context_copy_to_selected_list(
 
 /* Helpers for Operators */
 uiBut *UI_context_active_but_get(const struct bContext *C);
-void UI_context_active_but_prop_get(const struct bContext *C, struct 
PointerRNA *ptr, struct PropertyRNA **prop, int *index);
+void UI_context_active_but_prop_get(
+        const struct bContext *C,
+        struct PointerRNA *r_ptr, struct PropertyRNA **r_prop, int *r_index);
 void UI_context_active_but_prop_handle(struct bContext *C);
 struct wmOperator *UI_context_active_operator_get(const struct bContext *C);
 void UI_context_update_anim_flag(const struct bContext *C);
-void UI_context_active_but_prop_get_filebrowser(const struct bContext *C, 
struct PointerRNA *r_ptr, struct PropertyRNA **r_prop, bool *r_is_undo);
-void UI_context_active_but_prop_get_templateID(struct bContext *C, struct 
PointerRNA *ptr, struct PropertyRNA **prop);
+void UI_context_active_but_prop_get_filebrowser(
+        const struct bContext *C,
+        struct PointerRNA *r_ptr, struct PropertyRNA **r_prop, bool 
*r_is_undo);
+void UI_context_active_but_prop_get_templateID(
+        struct bContext *C,
+        struct PointerRNA *r_ptr, struct PropertyRNA **r_prop);
 
 /* Styled text draw */
 void UI_fontstyle_set(const struct uiFontStyle *fs);
diff --git a/source/blender/editors/interface/interface_handlers.c 
b/source/blender/editors/interface/interface_handlers.c
index 133487e..dd82389 100644
--- a/source/blender/editors/interface/interface_handlers.c
+++ b/source/blender/editors/interface/interface_handlers.c
@@ -8013,20 +8013,21 @@ uiBut *UI_context_active_but_get(const struct bContext 
*C)
 }
 
 /* helper function for insert keyframe, reset to default, etc operators */
-void UI_context_active_but_prop_get(const bContext *C, struct PointerRNA *ptr, 
struct PropertyRNA **prop, int *index)
+void UI_context_active_but_prop_get(
+        const bContext *C,
+        struct PointerRNA *r_ptr, struct PropertyRNA **r_prop, int *r_index)
 {
        uiBut *activebut = ui_context_rna_button_active(C);
 
-       memset(ptr, 0, sizeof(*ptr));
-
        if (activebut && activebut->rnapoin.data) {
-               *ptr = activebut->rnapoin;
-               *prop = activebut->rnaprop;
-               *index = activebut->rnaindex;
+               *r_ptr = activebut->rnapoin;
+               *r_prop = activebut->rnaprop;
+               *r_index = activebut->rnaindex;
        }
        else {
-               *prop = NULL;
-               *index = 0;
+               memset(r_ptr, 0, sizeof(*r_ptr));
+               *r_prop = NULL;
+               *r_index = 0;
        }
 }
 
diff --git a/source/blender/editors/interface/interface_templates.c 
b/source/blender/editors/interface/interface_templates.c
index 9f0c4b1..7f276bc 100644
--- a/source/blender/editors/interface/interface_templates.c
+++ b/source/blender/editors/interface/interface_templates.c
@@ -232,15 +232,17 @@ static uiBlock *id_search_menu(bContext *C, ARegion *ar, 
void *arg_litem)
 /* This is for browsing and editing the ID-blocks used */
 
 /* for new/open operators */
-void UI_context_active_but_prop_get_templateID(bContext *C, PointerRNA *ptr, 
PropertyRNA **prop)
+void UI_context_active_but_prop_get_templateID(
+       bContext *C,
+       PointerRNA *r_ptr, PropertyRNA **r_prop)
 {
        TemplateID *template;
        ARegion *ar = CTX_wm_region(C);
        uiBlock *block;
        uiBut *but;
 
-       memset(ptr, 0, sizeof(*ptr));
-       *prop = NULL;
+       memset(r_ptr, 0, sizeof(*r_ptr));
+       *r_prop = NULL;
 
        if (!ar)
                return;
@@ -251,8 +253,8 @@ void UI_context_active_but_prop_get_templateID(bContext *C, 
PointerRNA *ptr, Pro
                        if ((but->flag & (UI_BUT_LAST_ACTIVE | UI_ACTIVE))) {
                                if (but->func_argN) {
                                        template = but->func_argN;
-                                       *ptr = template->ptr;
-                                       *prop = template->prop;
+                                       *r_ptr = template->ptr;
+                                       *r_prop = template->prop;
                                        return;
                                }
                        }

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to