FIXME: Add a more explicit sort order in the window structure.
| 5979 | |
| 5980 | // FIXME: Add a more explicit sort order in the window structure. |
| 5981 | static int IMGUI_CDECL ChildWindowComparer(const void* lhs, const void* rhs) |
| 5982 | { |
| 5983 | const ImGuiWindow* const a = *(const ImGuiWindow* const *)lhs; |
| 5984 | const ImGuiWindow* const b = *(const ImGuiWindow* const *)rhs; |
| 5985 | if (int d = (a->Flags & ImGuiWindowFlags_Popup) - (b->Flags & ImGuiWindowFlags_Popup)) |
| 5986 | return d; |
| 5987 | if (int d = (a->Flags & ImGuiWindowFlags_Tooltip) - (b->Flags & ImGuiWindowFlags_Tooltip)) |
| 5988 | return d; |
| 5989 | return a->BeginOrderWithinParent - b->BeginOrderWithinParent; |
| 5990 | } |
| 5991 | |
| 5992 | static void AddWindowToSortBuffer(ImVector<ImGuiWindow*>* out_sorted_windows, ImGuiWindow* window) |
| 5993 | { |
nothing calls this directly
no outgoing calls
no test coverage detected