vvvv / VL.StandardLibs

A collection of standard libraries for vvvv including VL.Stride, VL.Skia, VL.ImGui, msgpack.org[VL]
https://visualprogramming.net
GNU Lesser General Public License v3.0
40 stars 15 forks source link

Modal Window and Popup Window are very similar #44

Closed antongit closed 2 years ago

antongit commented 2 years ago

These two are very similar. Maybe there should be only one PopupWindow with the IsModal pin? For now - they are two individual classes, that have their own Open and Close operations (as nodes). Should we at least have one set of Open and Close nodes, that close both windows? Internally these calls are the same: ImGui.OpenPopup(Label ?? string.Empty); ImGui.CloseCurrentPopup(); (inside begin/end)

See HowTo Modal Window, HowTo Popup.

Docs: https://github.com/ocornut/imgui/blob/873e9d35acb4d629a5ba06a312201edff8b9d0f6/imgui.h#L662 and https://github.com/ocornut/imgui/blob/873e9d35acb4d629a5ba06a312201edff8b9d0f6/imgui.h#L686