diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2011-06-30 15:48:07 +0000 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2011-06-30 15:48:07 +0000 |
commit | eddae6af0663243a2677674d501f9a87d55798f5 (patch) | |
tree | 08562171f870a6b592d624adfbfd0d6fa11fcdcb /gtk/thumbnail.c | |
parent | a5dc6b9e6637c85d18510ac6446ee4a8a7955e7b (diff) | |
download | netsurf-eddae6af0663243a2677674d501f9a87d55798f5.tar.gz netsurf-eddae6af0663243a2677674d501f9a87d55798f5.tar.bz2 |
Remove plotter table global. Pass a redraw context around redraw functions. Knockout could be handled better. Note: untested on most front ends.
svn path=/trunk/netsurf/; revision=12543
Diffstat (limited to 'gtk/thumbnail.c')
-rw-r--r-- | gtk/thumbnail.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/gtk/thumbnail.c b/gtk/thumbnail.c index 3561ea05b..c70c06546 100644 --- a/gtk/thumbnail.c +++ b/gtk/thumbnail.c @@ -61,6 +61,11 @@ bool thumbnail_create(hlcache_handle *content, struct bitmap *bitmap, GdkPixbuf *big; double scale; + struct redraw_context ctx = { + .interactive = false, + .plot = &nsgtk_plotters + }; + assert(content); assert(bitmap); @@ -95,9 +100,6 @@ bool thumbnail_create(hlcache_handle *content, struct bitmap *bitmap, gdk_drawable_set_colormap(pixmap, gdk_colormap_get_system()); - /* set the plotting functions up */ - plot = nsgtk_plotters; - /* set to plot to pixmap */ current_drawable = pixmap; current_gc = gdk_gc_new(current_drawable); @@ -106,7 +108,7 @@ bool thumbnail_create(hlcache_handle *content, struct bitmap *bitmap, #endif /* render the content */ - thumbnail_redraw(content, cwidth, cheight); + thumbnail_redraw(content, cwidth, cheight, &ctx); /* get the pixbuf we rendered the content into */ big = gdk_pixbuf_get_from_drawable(NULL, pixmap, NULL, 0, 0, 0, 0, |