mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
Fix an edge case
This commit is contained in:
parent
1655817bf7
commit
3a8d2c8e90
1 changed files with 9 additions and 0 deletions
|
|
@ -44,6 +44,15 @@ impl Folder {
|
|||
|
||||
if self.page == old {
|
||||
emit!(Pages(self.page)); // Force update
|
||||
match MANAGER.layout.folder_height() {
|
||||
limit if limit > 0 => {
|
||||
let max_page = (self.files.len() + limit - 1) / limit;
|
||||
if self.page + 1 < max_page {
|
||||
emit!(Pages(self.page + 1));
|
||||
}
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
}
|
||||
|
||||
true
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue