1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/gfx/cairo/quartz-mark-dirty.patch Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,56 @@ 1.4 +Date: Thu Jan 5 18:40:01 2012 -0500 1.5 + 1.6 +Bug 715704. Add a quartz implementation of mark_dirty_rectangle. r=roc 1.7 + 1.8 +We need to drop our CGImage cache when the surface has been changed by outside users. 1.9 + 1.10 +diff --git a/gfx/cairo/cairo/src/cairo-quartz-surface.c b/gfx/cairo/cairo/src/cairo-quartz-surface.c 1.11 +--- a/gfx/cairo/cairo/src/cairo-quartz-surface.c 1.12 ++++ b/gfx/cairo/cairo/src/cairo-quartz-surface.c 1.13 +@@ -3116,16 +3116,27 @@ _cairo_quartz_surface_clipper_intersect_ 1.14 + CGContextEOClip (surface->cgContext); 1.15 + } 1.16 + 1.17 + ND((stderr, "-- intersect_clip_path\n")); 1.18 + 1.19 + return CAIRO_STATUS_SUCCESS; 1.20 + } 1.21 + 1.22 ++static cairo_status_t 1.23 ++_cairo_quartz_surface_mark_dirty_rectangle (void *abstract_surface, 1.24 ++ int x, int y, 1.25 ++ int width, int height) 1.26 ++{ 1.27 ++ cairo_quartz_surface_t *surface = (cairo_quartz_surface_t *) abstract_surface; 1.28 ++ _cairo_quartz_surface_will_change (surface); 1.29 ++ return CAIRO_STATUS_SUCCESS; 1.30 ++} 1.31 ++ 1.32 ++ 1.33 + // XXXtodo implement show_page; need to figure out how to handle begin/end 1.34 + 1.35 + static const struct _cairo_surface_backend cairo_quartz_surface_backend = { 1.36 + CAIRO_SURFACE_TYPE_QUARTZ, 1.37 + _cairo_quartz_surface_create_similar, 1.38 + _cairo_quartz_surface_finish, 1.39 + _cairo_quartz_surface_acquire_image, 1.40 + _cairo_quartz_surface_release_source_image, 1.41 +@@ -3138,17 +3149,17 @@ static const struct _cairo_surface_backe 1.42 + NULL, /* create_span_renderer */ 1.43 + NULL, /* check_span_renderer */ 1.44 + NULL, /* copy_page */ 1.45 + NULL, /* show_page */ 1.46 + _cairo_quartz_surface_get_extents, 1.47 + NULL, /* old_show_glyphs */ 1.48 + NULL, /* get_font_options */ 1.49 + NULL, /* flush */ 1.50 +- NULL, /* mark_dirty_rectangle */ 1.51 ++ _cairo_quartz_surface_mark_dirty_rectangle, 1.52 + NULL, /* scaled_font_fini */ 1.53 + NULL, /* scaled_glyph_fini */ 1.54 + 1.55 + _cairo_quartz_surface_paint, 1.56 + _cairo_quartz_surface_mask, 1.57 + _cairo_quartz_surface_stroke, 1.58 + _cairo_quartz_surface_fill, 1.59 + _cairo_quartz_surface_show_glyphs,