Commit 2587d4b8 authored by Benjamin Otte's avatar Benjamin Otte

pixelcache: Add map/unmap functions

Because GTK does not invalidate windows that aren't mapped, we cannot
update the pixel cache when the window it handles isn't mapped. So we
add API to call when GDK windows get mapped/unmapped.
parent 2a9d2a96
......@@ -467,3 +467,15 @@ _gtk_pixel_cache_draw (GtkPixelCache *cache,
draw (cr, user_data);
_gtk_pixel_cache_map (GtkPixelCache *cache)
_gtk_pixel_cache_invalidate (cache, NULL);
_gtk_pixel_cache_unmap (GtkPixelCache *cache)
gtk_pixel_cache_blow_cache (cache);
......@@ -32,6 +32,8 @@ typedef void (*GtkPixelCacheDrawFunc) (cairo_t *cr,
GtkPixelCache *_gtk_pixel_cache_new (void);
void _gtk_pixel_cache_free (GtkPixelCache *cache);
void _gtk_pixel_cache_map (GtkPixelCache *cache);
void _gtk_pixel_cache_unmap (GtkPixelCache *cache);
void _gtk_pixel_cache_invalidate (GtkPixelCache *cache,
cairo_region_t *region);
void _gtk_pixel_cache_draw (GtkPixelCache *cache,
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment