Pop trailing draw command (used before merging or presenting to user) Note that this leaves the ImDrawList in a state unfit for further commands, as most code assume that CmdBuffer.Size > 0 && CmdBuffer.back().UserCallback == NULL
| 460 | // Pop trailing draw command (used before merging or presenting to user) |
| 461 | // Note that this leaves the ImDrawList in a state unfit for further commands, as most code assume that CmdBuffer.Size > 0 && CmdBuffer.back().UserCallback == NULL |
| 462 | void ImDrawList::_PopUnusedDrawCmd() |
| 463 | { |
| 464 | while (CmdBuffer.Size > 0) |
| 465 | { |
| 466 | ImDrawCmd* curr_cmd = &CmdBuffer.Data[CmdBuffer.Size - 1]; |
| 467 | if (curr_cmd->ElemCount != 0 || curr_cmd->UserCallback != NULL) |
| 468 | return;// break; |
| 469 | CmdBuffer.pop_back(); |
| 470 | } |
| 471 | } |
| 472 | |
| 473 | void ImDrawList::AddCallback(ImDrawCallback callback, void* callback_data) |
| 474 | { |
no outgoing calls
no test coverage detected