Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[bug] Fix imgui_context in destroying multiple GGUI windows (taichi-d…
…ev#7812) Issue: taichi-dev#7769 ### Brief Summary <!-- copilot:summary --> ### <samp>🤖 Generated by Copilot at a9fa9e7</samp> Refactored the `GUI` class in the Vulkan backend to use a local ImGui context and added a test case for multiple windows. This improves the modularity and robustness of the `GUI` class and its usage. ### Walkthrough <!-- copilot:walkthrough --> ### <samp>🤖 Generated by Copilot at a9fa9e7</samp> * Add `imgui_context_` member variable to `GUI` class to store and manage its own ImGui context ([link](https://github.com/taichi-dev/taichi/pull/7812/files?diff=unified&w=0#diff-aa837ca266d11faa9968cd0aad76e18080fd5a9d4110ac1a6d6ccd128aee7a4bL25-R25), [link](https://github.com/taichi-dev/taichi/pull/7812/files?diff=unified&w=0#diff-aa837ca266d11faa9968cd0aad76e18080fd5a9d4110ac1a6d6ccd128aee7a4bL238-R238), [link](https://github.com/taichi-dev/taichi/pull/7812/files?diff=unified&w=0#diff-0bd71968053eb6c3a4cbb725ceebe181a7c5b3bef5207e525855ce8980e1bd35L65-R67)) * Initialize `app_context_` and `swap_chain_` member variables with `nullptr` in `GUI` class header file ([link](https://github.com/taichi-dev/taichi/pull/7812/files?diff=unified&w=0#diff-0bd71968053eb6c3a4cbb725ceebe181a7c5b3bef5207e525855ce8980e1bd35L65-R67)) * Add test case to check if `GUI` class can support multiple windows in `test_ggui.py` ([link](https://github.com/taichi-dev/taichi/pull/7812/files?diff=unified&w=0#diff-7f78177ffeb214e2e6edde3b288143eb941d514aaf0d1471e4038b5ddf11538eR1019-R1025))
- Loading branch information