Merge pull request #82660 from coumcashier/itemlist_height_fix

Fix storing invalid item height values in `ItemList`
This commit is contained in:
Rémi Verschelde 2023-11-10 21:54:33 +01:00
commit 7f8edaa238
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -1431,11 +1431,11 @@ void ItemList::force_update_list_size() {
}
}
for (int j = items.size() - 1; j >= 0 && col > 0; j--, col--) {
items.write[j].rect_cache.size.y = max_h;
}
if (all_fit) {
for (int j = items.size() - 1; j >= 0 && col > 0; j--, col--) {
items.write[j].rect_cache.size.y = max_h;
}
float page = MAX(0, size.height - theme_cache.panel_style->get_minimum_size().height);
float max = MAX(page, ofs.y + max_h);
if (auto_height) {