Jason Lee 2024-03-05 21:54:48 +08:00 committed by GitHub
parent 537d92533c
commit 0b34b1de7b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 7 additions and 5 deletions

View file

@ -241,7 +241,7 @@ impl ListState {
let mut cursor = state.items.cursor::<ListItemSummary>();
cursor.seek(&Count(ix + 1), Bias::Right, &());
let bottom = cursor.start().height + padding.top;
let goal_top = px(0.).max(bottom - height);
let goal_top = px(0.).max(bottom - height + padding.bottom);
cursor.seek(&Height(goal_top), Bias::Left, &());
let start_ix = cursor.start().count;