diff options
Diffstat (limited to 'source/blender/editors/include')
-rw-r--r-- | source/blender/editors/include/ED_select_utils.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/source/blender/editors/include/ED_select_utils.h b/source/blender/editors/include/ED_select_utils.h index dbe1b582132..fa02ebe18f6 100644 --- a/source/blender/editors/include/ED_select_utils.h +++ b/source/blender/editors/include/ED_select_utils.h @@ -14,6 +14,7 @@ extern "C" { struct KDTree_1d; struct wmOperator; +struct wmOperatorType; enum { SEL_TOGGLE = 0, @@ -96,16 +97,23 @@ struct SelectPick_Params { /** * Utility to get #eSelectPickMode from booleans for convenience. */ -eSelectOp ED_select_op_from_operator(struct wmOperator *op) +eSelectOp ED_select_op_from_operator(struct PointerRNA *ptr) ATTR_NONNULL(1) ATTR_WARN_UNUSED_RESULT; /** * Initialize `params` from `op`, * these properties are defined by #WM_operator_properties_mouse_select. */ -void ED_select_pick_params_from_operator(struct wmOperator *op, struct SelectPick_Params *params) +void ED_select_pick_params_from_operator(struct PointerRNA *ptr, struct SelectPick_Params *params) ATTR_NONNULL(1, 2); +/** + * Get-name callback for #wmOperatorType.get_name, this is mainly useful so the selection + * action is shown in the status-bar. + */ +const char *ED_select_pick_get_name(struct wmOperatorType *ot, PointerRNA *ptr); +const char *ED_select_circle_get_name(struct wmOperatorType *ot, PointerRNA *ptr); + #ifdef __cplusplus } #endif |