From dcd6beeb83e286ba64ad60f7da375f9959e69487 Mon Sep 17 00:00:00 2001 From: Pascal Thomet Date: Thu, 19 Dec 2024 08:01:32 +0100 Subject: [PATCH] demo_imgui_bundle: band aid fix for #293, c++ side --- bindings/imgui_bundle/demos_cpp/demo_imgui_bundle.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bindings/imgui_bundle/demos_cpp/demo_imgui_bundle.cpp b/bindings/imgui_bundle/demos_cpp/demo_imgui_bundle.cpp index f34ba28a..021832ef 100644 --- a/bindings/imgui_bundle/demos_cpp/demo_imgui_bundle.cpp +++ b/bindings/imgui_bundle/demos_cpp/demo_imgui_bundle.cpp @@ -29,7 +29,8 @@ using VoidFunction = std::function; void ShowModuleDemo(const std::string& demoFilename, VoidFunction demoFunction) { - + if (ImGui::GetFrameCount() < 2) // cf https://github.com/pthom/imgui_bundle/issues/293 + return; if (ImGui::CollapsingHeader("Code for this demo")) ShowPythonVsCppFile(demoFilename.c_str()); demoFunction();