1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-02-04 03:40:07 +00:00

TreeView: Fix getAllVisibleItems() when only the final row of the tree fits in the viewport

Fixes #1118
This commit is contained in:
reuk 2023-01-19 20:00:22 +00:00
parent 621e5e3de4
commit db90a31813
No known key found for this signature in database
GPG key ID: 9ADCD339CFC98A11

View file

@ -647,7 +647,7 @@ private:
auto* i = owner.rootItemVisible ? owner.rootItem
: owner.rootItem->subItems.getFirst();
while (i != nullptr && i->y < visibleTop)
while (i != nullptr && i->y + i->getItemHeight() < visibleTop)
i = getNextVisibleItem (i, true);
return i;