Customize display duration

This commit is contained in:
Jean-Loup Beaussart 2024-12-11 00:02:54 +01:00
parent 3c0124bcd0
commit c60eaf29f9
No known key found for this signature in database
GPG Key ID: 582B3C35EAFE46F8
2 changed files with 3 additions and 2 deletions

View File

@ -1 +1,2 @@
photo_path: "/mnt/c/Users/beaus/Downloads"
photo_path: "/mnt/c/Users/beaus/Downloads"
duration: 30

View File

@ -47,7 +47,7 @@ async fn main() -> anyhow::Result<()> {
display_frame(&provider)?;
if time.elapsed().as_secs() > 5 {
if time.elapsed() > settings.duration {
provider.load_next_image()?;
time = Instant::now();
}