From 3a3c4bef42985b2ac803ac231867ae1ee0052be9 Mon Sep 17 00:00:00 2001 From: Andre Weissflog Date: Thu, 7 Nov 2024 18:56:55 +0100 Subject: [PATCH] sokol_gfx_imgui.h: fix Dear ImGui conflicting ID warning (fixes #1144) --- util/sokol_gfx_imgui.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/util/sokol_gfx_imgui.h b/util/sokol_gfx_imgui.h index 24212f69b..476e1471b 100644 --- a/util/sokol_gfx_imgui.h +++ b/util/sokol_gfx_imgui.h @@ -3434,6 +3434,7 @@ _SOKOL_PRIVATE void _sgimgui_draw_sampler_panel(sgimgui_t* ctx, sg_sampler smp) _SOKOL_PRIVATE void _sgimgui_draw_shader_func(const char* title, const sg_shader_function* func) { SOKOL_ASSERT(func); + igPushID_Str(title); igText("%s", title); if (func->entry) { igText(" entry: %s", func->entry); @@ -3452,6 +3453,7 @@ _SOKOL_PRIVATE void _sgimgui_draw_shader_func(const char* title, const sg_shader igTreePop(); } } + igPopID(); } _SOKOL_PRIVATE void _sgimgui_draw_shader_panel(sgimgui_t* ctx, sg_shader shd) {