From 8ad55e23fdf375278dfb381b9641596e0852a9d8 Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Mon, 11 Nov 2019 21:49:41 +0000 Subject: gif: Change how we rate-limit frames to match other browsers. This makes the old minimum_gif_delay option unused. --- content/handlers/image/gif.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'content/handlers') diff --git a/content/handlers/image/gif.c b/content/handlers/image/gif.c index fa343fbac..fa09f401c 100644 --- a/content/handlers/image/gif.c +++ b/content/handlers/image/gif.c @@ -154,8 +154,10 @@ static void nsgif_animate(void *p) /* Continue animating if we should */ if (gif->gif->loop_count >= 0) { delay = gif->gif->frames[gif->current_frame].frame_delay; - if (delay < nsoption_int(minimum_gif_delay)) - delay = nsoption_int(minimum_gif_delay); + if (delay <= 1) { + /* Assuming too fast to be intended, set default. */ + delay = 10; + } guit->misc->schedule(delay * 10, nsgif_animate, gif); } -- cgit v1.2.3