From 13f5ebbf07a369c7460a2539b87be9a55375d0c6 Mon Sep 17 00:00:00 2001 From: Marc-André Lureau Date: Mon, 19 Mar 2012 19:50:45 +0100 Subject: Hide cursor when it is on a different screen in server mode When the cursor shape is changed, all the cursor channels are updated. The current code assumed that the "set" of the shape should show the cursor, but it should stay hidden instead. Also, when the cursor is hidden, we must invalidate its current region to redraw display. Fix: https://bugzilla.redhat.com/show_bug.cgi?id=804308 --- gtk/spice-widget-cairo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'gtk/spice-widget-cairo.c') diff --git a/gtk/spice-widget-cairo.c b/gtk/spice-widget-cairo.c index 3fc2a22..2f1ef75 100644 --- a/gtk/spice-widget-cairo.c +++ b/gtk/spice-widget-cairo.c @@ -103,7 +103,8 @@ void spicex_draw_event(SpiceDisplay *display, cairo_t *cr) } cairo_paint(cr); - if (d->mouse_mode == SPICE_MOUSE_MODE_SERVER) { + if (d->mouse_mode == SPICE_MOUSE_MODE_SERVER && + !d->show_cursor) { GdkPixbuf *image = d->mouse_pixbuf; if (image != NULL) { gdk_cairo_set_source_pixbuf(cr, image, -- cgit v1.2.3