diff --git a/build-aux/flatpak/org.gnome.Loupe.Devel.json b/build-aux/flatpak/org.gnome.Loupe.Devel.json index af7895d..db4a00d 100644 --- a/build-aux/flatpak/org.gnome.Loupe.Devel.json +++ b/build-aux/flatpak/org.gnome.Loupe.Devel.json @@ -159,7 +159,7 @@ { "type": "git", "url": "https://gitlab.gnome.org/sophie-h/glycin.git", - "commit": "4b0759839322fad9277c7f823438abe4937e4027" + "commit": "9701eb7ac36cd85ce75241bf50dfe325b50f54c9" } ] }, diff --git a/src/decoder/tiling.rs b/src/decoder/tiling.rs index 9656268..55185b1 100644 --- a/src/decoder/tiling.rs +++ b/src/decoder/tiling.rs @@ -648,12 +648,13 @@ impl SharedFrameBuffer { /// Return true if the next frame should be shown and removes the outdated /// frame pub fn frame_timeout(&self, elapsed: Duration) -> bool { - if self - .buffer - .load() - .images - .front() - .is_some_and(|next_frame| elapsed >= next_frame.delay) + let images = &self.buffer.load().images; + + // Only move to next image if there is one buffered + if images.len() > 1 + && images + .front() + .is_some_and(|next_frame| elapsed >= next_frame.delay) { self.next_frame(); return true;