]> www.fi.muni.cz Git - evince.git/blobdiff - backend/dvi/cairo-device.c
dvi: Add image_done method to DviDevice to notify that the image is finished
[evince.git] / backend / dvi / cairo-device.c
index 47425cad7e0be21a503a449c8fff618f525c35bb..51aea3790c5fe2d6501db737e759740d87242012 100644 (file)
@@ -259,6 +259,12 @@ dvi_cairo_put_pixel (void *image, int x, int y, Ulong color)
        *p = color;
 }
 
+static void
+dvi_cairo_image_done (void *ptr)
+{
+        cairo_surface_mark_dirty((cairo_surface_t *)ptr);
+}
+
 static void
 dvi_cairo_set_color (void *device_data, Ulong fg, Ulong bg)
 {
@@ -280,6 +286,7 @@ mdvi_cairo_device_init (DviDevice *device)
        device->create_image = dvi_cairo_create_image;
        device->free_image = dvi_cairo_free_image;
        device->put_pixel = dvi_cairo_put_pixel;
+        device->image_done = dvi_cairo_image_done;
        device->set_color = dvi_cairo_set_color;
 #ifdef HAVE_SPECTRE
        device->draw_ps = dvi_cairo_draw_ps;