Update deps & remove build_most_optimized comment since benchmarks indicate it's false

This commit is contained in:
itsjunetime
2024-10-08 15:05:27 -06:00
parent ab7a3357a1
commit f6d339923b
5 changed files with 184 additions and 207 deletions
+3 -7
View File
@@ -287,10 +287,9 @@ impl Tui {
}
pub fn set_n_pages(&mut self, n_pages: usize) {
self.rendered = Vec::with_capacity(n_pages);
for _ in 0..n_pages {
self.rendered.push(RenderedInfo::default());
}
self.rendered = std::iter::from_fn(|| Some(RenderedInfo::default()))
.take(n_pages)
.collect();
self.page = self.page.min(n_pages - 1);
}
@@ -479,9 +478,6 @@ impl Tui {
_ => None
},
Event::Resize(_, _) => Some(InputAction::Redraw),
// One of these options is Event::Resize, and we don't care about that because
// we always check, regardless, if the available area for the images has
// changed.
_ => None
}
}