From ee70eb96cf321e8aca2248b96c64680a33c7766f Mon Sep 17 00:00:00 2001 From: Yevgeny Makarov Date: Sun, 6 Dec 2020 11:17:51 -0800 Subject: UI: Alert Dialog Helper Function Shared helper function to create a split layout with an alert icon for popup dialogs. Differential Revision: https://developer.blender.org/D9486 Reviewed by Julian Eisel --- source/blender/editors/include/UI_interface.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'source/blender/editors/include') diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h index a190194d89d..005dbf0e381 100644 --- a/source/blender/editors/include/UI_interface.h +++ b/source/blender/editors/include/UI_interface.h @@ -26,6 +26,7 @@ #include "BLI_compiler_attrs.h" #include "BLI_sys_types.h" /* size_t */ #include "RNA_types.h" +#include "UI_interface_icons.h" #ifdef __cplusplus extern "C" { @@ -2431,6 +2432,9 @@ void uiItemTabsEnumR_prop(uiLayout *layout, /* Only for testing, inspecting layouts. */ const char *UI_layout_introspect(uiLayout *layout); +/* Helper to add a big icon and create a split layout for alert boxes. */ +uiLayout *uiItemsAlertBox(uiBlock *block, const int size, const eAlertIcon icon); + /* UI Operators */ typedef struct uiDragColorHandle { float color[3]; -- cgit v1.2.3