interception-team / imgui-animated

MIT License
34 stars 2 forks source link

How to Add Window on pressing toggle button #1

Closed svkvarun43 closed 2 years ago

svkvarun43 commented 2 years ago

Hi

How do I open a window when I have pressed the toggle button ( moved to right ) with the syntax you have provided

Currently I have

if(ImGui::Toggle("Toggle button", &connections_window));

which opens a window instantly without me pressing the toggle button.

This would be really helpful

Thankyou

bludeck commented 2 years ago

Are you checking for value of connections_window before drawing a window?

bludeck commented 2 years ago

Closed due to inactivity.