diff options
author | Frediano Ziglio <fziglio@redhat.com> | 2016-02-08 19:57:58 +0000 |
---|---|---|
committer | Frediano Ziglio <fziglio@redhat.com> | 2016-02-11 23:51:46 +0000 |
commit | fbdea0fa790ba3f836fe0c6d60441b716c7d0bd3 (patch) | |
tree | 94eaed791f1a01280973e08988e864c45c3c60b6 /server/display-channel.c | |
parent | 79e50495fe53a34cdbf2e524da2dcac4e11ee811 (diff) |
CommonChannel: hold a reference to QXLInstance instead of RedWorker
CommonChannel does not need to know about RedWorker.
This reduce a bit dependencies between objects.
Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Acked-by: Jonathon Jongsma <jjongsma@redhat.com>
Diffstat (limited to 'server/display-channel.c')
-rw-r--r-- | server/display-channel.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/server/display-channel.c b/server/display-channel.c index 78c984fd..28304b3e 100644 --- a/server/display-channel.c +++ b/server/display-channel.c @@ -241,8 +241,7 @@ static void stop_streams(DisplayChannel *display) void display_channel_surface_unref(DisplayChannel *display, uint32_t surface_id) { RedSurface *surface = &display->surfaces[surface_id]; - RedWorker *worker = COMMON_CHANNEL(display)->worker; - QXLInstance *qxl = red_worker_get_qxl(worker); + QXLInstance *qxl = display->common.qxl; DisplayChannelClient *dcc; RingItem *link, *next; @@ -1445,7 +1444,7 @@ void display_channel_drawable_unref(DisplayChannel *display, Drawable *drawable) ring_remove(item); } if (drawable->red_drawable) { - red_drawable_unref(COMMON_CHANNEL(display)->worker, drawable->red_drawable, drawable->group_id); + red_drawable_unref(display, drawable->red_drawable, drawable->group_id); } drawable_free(display, drawable); display->drawable_count--; @@ -2155,8 +2154,7 @@ void display_channel_gl_scanout(DisplayChannel *display) static void set_gl_draw_async_count(DisplayChannel *display, int num) { - RedWorker *worker = COMMON_CHANNEL(display)->worker; - QXLInstance *qxl = red_worker_get_qxl(worker); + QXLInstance *qxl = display->common.qxl; display->gl_draw_async_count = num; |