Fix scroll offset calculation
This commit is contained in:
parent
32e8616ed7
commit
7880f3389c
1 changed files with 2 additions and 2 deletions
|
|
@ -82,8 +82,8 @@ impl Rooms {
|
||||||
// height - len + index <= line
|
// height - len + index <= line
|
||||||
.max(height - rooms.len() as i32 + cursor.index as i32)
|
.max(height - rooms.len() as i32 + cursor.index as i32)
|
||||||
// Make sure there is no free space above the room list:
|
// Make sure there is no free space above the room list:
|
||||||
// line <= len
|
// line <= index
|
||||||
.min(rooms.len() as i32);
|
.min(cursor.index as i32);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue