| 3388 | } |
| 3389 | |
| 3390 | void ImGuiListClipper::IncludeItemsByIndex(int item_begin, int item_end) |
| 3391 | { |
| 3392 | ImGuiListClipperData* data = (ImGuiListClipperData*)TempData; |
| 3393 | IM_ASSERT(DisplayStart < 0); // Only allowed after Begin() and if there has not been a specified range yet. |
| 3394 | IM_ASSERT(item_begin <= item_end); |
| 3395 | if (item_begin < item_end) |
| 3396 | data->Ranges.push_back(ImGuiListClipperRange::FromIndices(item_begin, item_end)); |
| 3397 | } |
| 3398 | |
| 3399 | // This is already called while stepping. |
| 3400 | // The ONLY reason you may want to call this is if you passed INT_MAX to ImGuiListClipper::Begin() because you couldn't step item count beforehand. |