mirror of
https://github.com/ocornut/imgui.git
synced 2024-11-13 18:50:58 +01:00
Clipper: Fixed a bug if attempt to force-include a range which matches an already included range. (#3841)
This commit is contained in:
parent
bdd9b96fa3
commit
a066074054
@ -61,6 +61,8 @@ Other changes:
|
|||||||
- ColorEdit, ColorPicker: Manipulating options popup don't mark item as edited. (#6722)
|
- ColorEdit, ColorPicker: Manipulating options popup don't mark item as edited. (#6722)
|
||||||
(Note that they may still be marked as Active/Hovered.)
|
(Note that they may still be marked as Active/Hovered.)
|
||||||
- Clipper: Added IncludeItemByIndex() helper to include a single item. (#6424, #3841)
|
- Clipper: Added IncludeItemByIndex() helper to include a single item. (#6424, #3841)
|
||||||
|
- Clipper: Fixed a bug if attempt to force-include a range which matches an already
|
||||||
|
included range, clipper would end earlier. (#3841)
|
||||||
- ImDrawData: Fixed an issue where TotalVtxCount/TotalIdxCount does not match the sum
|
- ImDrawData: Fixed an issue where TotalVtxCount/TotalIdxCount does not match the sum
|
||||||
of individual ImDrawList's buffer sizes when a dimming/modal background is rendered. (#6716)
|
of individual ImDrawList's buffer sizes when a dimming/modal background is rendered. (#6716)
|
||||||
- ImDrawList: Automatically calling ChannelsMerge() if not done after a split.
|
- ImDrawList: Automatically calling ChannelsMerge() if not done after a split.
|
||||||
|
@ -2975,13 +2975,15 @@ static bool ImGuiListClipper_StepInternal(ImGuiListClipper* clipper)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Step 0+ (if item height is given in advance) or 1+: Display the next range in line.
|
// Step 0+ (if item height is given in advance) or 1+: Display the next range in line.
|
||||||
if (data->StepNo < data->Ranges.Size)
|
while (data->StepNo < data->Ranges.Size)
|
||||||
{
|
{
|
||||||
clipper->DisplayStart = ImMax(data->Ranges[data->StepNo].Min, already_submitted);
|
clipper->DisplayStart = ImMax(data->Ranges[data->StepNo].Min, already_submitted);
|
||||||
clipper->DisplayEnd = ImMin(data->Ranges[data->StepNo].Max, clipper->ItemsCount);
|
clipper->DisplayEnd = ImMin(data->Ranges[data->StepNo].Max, clipper->ItemsCount);
|
||||||
if (clipper->DisplayStart > already_submitted) //-V1051
|
if (clipper->DisplayStart > already_submitted) //-V1051
|
||||||
ImGuiListClipper_SeekCursorForItem(clipper, clipper->DisplayStart);
|
ImGuiListClipper_SeekCursorForItem(clipper, clipper->DisplayStart);
|
||||||
data->StepNo++;
|
data->StepNo++;
|
||||||
|
if (clipper->DisplayStart == clipper->DisplayEnd && data->StepNo < data->Ranges.Size)
|
||||||
|
continue;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
2
imgui.h
2
imgui.h
@ -26,7 +26,7 @@
|
|||||||
// Library Version
|
// Library Version
|
||||||
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals, e.g. '#if IMGUI_VERSION_NUM >= 12345')
|
// (Integer encoded as XYYZZ for use in #if preprocessor conditionals, e.g. '#if IMGUI_VERSION_NUM >= 12345')
|
||||||
#define IMGUI_VERSION "1.89.9 WIP"
|
#define IMGUI_VERSION "1.89.9 WIP"
|
||||||
#define IMGUI_VERSION_NUM 18984
|
#define IMGUI_VERSION_NUM 18985
|
||||||
#define IMGUI_HAS_TABLE
|
#define IMGUI_HAS_TABLE
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user