diff options
author | Richard Wilson <rjw@netsurf-browser.org> | 2005-01-23 15:20:45 +0000 |
---|---|---|
committer | Richard Wilson <rjw@netsurf-browser.org> | 2005-01-23 15:20:45 +0000 |
commit | 54f903d1b457a280f2cf0a677667428dd3dee239 (patch) | |
tree | 8976703a2352daaa12f4aa8f1d047e002a7179f8 /image/gif.c | |
parent | 1fb2e5f2c3a66ba68c0cc614cd567aa74f8b4e5a (diff) | |
download | netsurf-54f903d1b457a280f2cf0a677667428dd3dee239.tar.gz netsurf-54f903d1b457a280f2cf0a677667428dd3dee239.tar.bz2 |
[project @ 2005-01-23 15:20:45 by rjw]
Fix for first frame of a GIF animation not always being correctly cleared
svn path=/import/netsurf/; revision=1462
Diffstat (limited to 'image/gif.c')
-rw-r--r-- | image/gif.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/image/gif.c b/image/gif.c index be59c478c..617723bf3 100644 --- a/image/gif.c +++ b/image/gif.c @@ -216,11 +216,17 @@ void nsgif_animate(void *p) c->data.gif.gif->frames[c->data.gif.current_frame - 1].redraw_required; } else { /* do advanced check */ - data.redraw.full_redraw = !((c->data.gif.current_frame == 0) && - (bitmap_get_opaque(c->data.gif.gif->frame_image)) && - (data.redraw.x == 0) && (data.redraw.y == 0) && - (data.redraw.width = c->data.gif.gif->width) && - (data.redraw.height = c->data.gif.gif->height)); + if ((data.redraw.x == 0) && (data.redraw.y == 0) && + (data.redraw.width == c->data.gif.gif->width) && + (data.redraw.height == c->data.gif.gif->height)) { + data.redraw.full_redraw = bitmap_get_opaque(c->data.gif.gif->frame_image); + } else { + data.redraw.full_redraw = true; + data.redraw.x = 0; + data.redraw.y = 0; + data.redraw.width = c->data.gif.gif->width; + data.redraw.height = c->data.gif.gif->height; + } } /* other data */ |