diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2011-07-21 13:42:30 +0100 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2011-07-21 13:45:58 +0100 |
commit | 69cc802e61cd49871b84547131e59b99c9e48640 (patch) | |
tree | 4374a23f9fb90863b1ab179bf35765a0c0f66805 /src/cairo-surface-subsurface.c | |
parent | 8938f58e7065fe89d46d0bebc28143f0e7e72f48 (diff) | |
download | cairo-69cc802e61cd49871b84547131e59b99c9e48640.tar.gz |
Fix proxying of ->context_create()
Adrian Johnson found that I had broken show_page() and pinpointed the
cause to being that cairo_show_page() was being called on the recording
surface and not the pagination surface after my overhaul for
cairo_backend_t. In fact, the problem was far more severe as the mistake
caused the created context to point to the wrong surface entirely,
bypassing the surface proxy.
What is desired is for the proxy's target surface to choose what manner
of context is should use, but for all calls into the surface backend to
go through the proxy surface.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'src/cairo-surface-subsurface.c')
-rw-r--r-- | src/cairo-surface-subsurface.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cairo-surface-subsurface.c b/src/cairo-surface-subsurface.c index 2a4a4fb57..143c78efd 100644 --- a/src/cairo-surface-subsurface.c +++ b/src/cairo-surface-subsurface.c @@ -421,7 +421,7 @@ static cairo_t * _cairo_surface_subsurface_create_context(void *target) { cairo_surface_subsurface_t *surface = target; - return cairo_create (surface->target); + return surface->target->backend->create_context (&surface->base); } static const cairo_surface_backend_t _cairo_surface_subsurface_backend = { |