diff options
author | Alexander Larsson <alexl@redhat.com> | 2013-09-09 11:07:50 +0200 |
---|---|---|
committer | Alexander Larsson <alexl@redhat.com> | 2013-09-09 11:07:50 +0200 |
commit | 92edb7650086e1ec55b804a7d8032f220c740757 (patch) | |
tree | 5fa8e8466c49c30bccc6df035f84e6dc321792f8 /gtk/gtkpixelcache.c | |
parent | 9a45712ad674782841c83a01f810042ab92b60cd (diff) | |
download | gtk+-92edb7650086e1ec55b804a7d8032f220c740757.tar.gz |
Pixel cache: Add no-pixel-cache debug flag
This is useful for benchmarking comparisons, and to verify if bugs
happend with or without the pixel cache.
Diffstat (limited to 'gtk/gtkpixelcache.c')
-rw-r--r-- | gtk/gtkpixelcache.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gtk/gtkpixelcache.c b/gtk/gtkpixelcache.c index 2529f11845..ca6740f641 100644 --- a/gtk/gtkpixelcache.c +++ b/gtk/gtkpixelcache.c @@ -174,6 +174,11 @@ _gtk_pixel_cache_create_surface_if_needed (GtkPixelCache *cache, cairo_pattern_t *bg; double red, green, blue, alpha; +#ifdef G_ENABLE_DEBUG + if (gtk_get_debug_flags () & GTK_DEBUG_NO_PIXEL_CACHE) + return; +#endif + content = cache->content; if (!content) { |