From 828905190e12432228d88563e0dcb74054b488a9 Mon Sep 17 00:00:00 2001 From: Julian Eisel Date: Mon, 9 Sep 2019 16:34:16 +0200 Subject: UI: Refactor and improve buttton extra icons Without this patch there could only be one superimposed icon and the operators were hard coded for the button types. This keeps the previous, sort of predefined extra icons working in a rather generic way, but allows adding specific ones for specific case through `UI_but_extra_operator_icon_set()`. Reviewed by: Campbell Barton Differential Revision: https://developer.blender.org/D5730 --- source/blender/windowmanager/WM_types.h | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'source/blender/windowmanager/WM_types.h') diff --git a/source/blender/windowmanager/WM_types.h b/source/blender/windowmanager/WM_types.h index b3507c7e57e..5ecd3191bfb 100644 --- a/source/blender/windowmanager/WM_types.h +++ b/source/blender/windowmanager/WM_types.h @@ -775,6 +775,16 @@ typedef struct wmOperatorType { } wmOperatorType; +/** + * Wrapper to reference a wmOperatorType together with some set properties and othere relevant + * information to invoke the operator in a customizable way. + */ +typedef struct wmOperatorCallParams { + struct wmOperatorType *optype; + struct PointerRNA *opptr; + short opcontext; +} wmOperatorCallParams; + #ifdef WITH_INPUT_IME /* *********** Input Method Editor (IME) *********** */ /** -- cgit v1.2.3