Preview and gallery mode changes, part of #540

This commit is contained in:
Jeremy Soller 2024-10-02 13:23:41 -06:00
parent 18c1301820
commit 9b8844a884
No known key found for this signature in database
GPG key ID: D02FD439211AF56F
5 changed files with 12 additions and 4 deletions

View file

@ -850,6 +850,7 @@ pub enum Message {
Gallery(bool),
GalleryPrevious,
GalleryNext,
GalleryToggle,
GoNext,
GoPrevious,
ItemDown,
@ -2071,6 +2072,9 @@ impl Tab {
commands.push(Command::Iced(widget::button::focus(id)));
}
}
Message::GalleryToggle => {
self.gallery = !self.gallery;
}
Message::GoNext => {
if let Some(history_i) = self.history_i.checked_add(1) {
if let Some(location) = self.history.get(history_i) {