mirror of
https://github.com/netsurf-browser/netsurf
synced 2024-11-24 07:19:37 +03:00
Clear new bitmaps to transparent black on creation of gtk bitmaps.
svn path=/trunk/netsurf/; revision=3439
This commit is contained in:
parent
8aa4b9e7b3
commit
2370e4c6a0
@ -49,6 +49,11 @@ struct bitmap *bitmap_create(int width, int height, unsigned int state)
|
||||
|
||||
bmp->primary = gdk_pixbuf_new(GDK_COLORSPACE_RGB, true, 8,
|
||||
width, height);
|
||||
|
||||
/* fill the pixbuf in with 100% transparent black, as the memory
|
||||
* won't have been cleared.
|
||||
*/
|
||||
gdk_pixbuf_fill(bmp->primary, 0);
|
||||
bmp->pretile_x = bmp->pretile_y = bmp->pretile_xy = NULL;
|
||||
return bmp;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user