[gtk-vnc-devel] [PATCH 6/7] Fedora patch: avoid repainting for non-framebuffer requests 2008-11-24 Federico Mena Quintero <federico novell com>



	* src/gvnc.c (gvnc_framebuffer_update): Integrate
	Daniel Berrange's patch from Fedora to avoid painting on VNC requests
	that do not really refer to framebuffer updates.

Signed-off-by: Federico Mena Quintero <federico novell com>
---
 ChangeLog  |    6 ++++++
 src/gvnc.c |    8 ++++++--
 2 files changed, 12 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index a3d056b..ae2b4e5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2008-11-24  Federico Mena Quintero  <federico novell com>
 
+	* src/gvnc.c (gvnc_framebuffer_update): Integrate 
+	Daniel Berrange's patch from Fedora to avoid painting on VNC requests
+	that do not really refer to framebuffer updates.
+
+2008-11-24  Federico Mena Quintero  <federico novell com>
+
 	* src/vncdisplay.c (add_backing_store): New function; adds a
 	backing_store of Always to our window.
 	(realize): Add backing store (on the X-server side) to our window,
diff --git a/src/gvnc.c b/src/gvnc.c
index 4deff2c..93ecca6 100644
--- a/src/gvnc.c
+++ b/src/gvnc.c
@@ -1955,21 +1955,27 @@ static void gvnc_framebuffer_update(struct gvnc *gvnc, int32_t etype,
 	switch (etype) {
 	case GVNC_ENCODING_RAW:
 		gvnc_raw_update(gvnc, x, y, width, height);
+		gvnc_update(gvnc, x, y, width, height);
 		break;
 	case GVNC_ENCODING_COPY_RECT:
 		gvnc_copyrect_update(gvnc, x, y, width, height);
+		gvnc_update(gvnc, x, y, width, height);
 		break;
 	case GVNC_ENCODING_RRE:
 		gvnc_rre_update(gvnc, x, y, width, height);
+		gvnc_update(gvnc, x, y, width, height);
 		break;
 	case GVNC_ENCODING_HEXTILE:
 		gvnc_hextile_update(gvnc, x, y, width, height);
+		gvnc_update(gvnc, x, y, width, height);
 		break;
 	case GVNC_ENCODING_ZRLE:
 		gvnc_zrle_update(gvnc, x, y, width, height);
+		gvnc_update(gvnc, x, y, width, height);
 		break;
 	case GVNC_ENCODING_TIGHT:
 		gvnc_tight_update(gvnc, x, y, width, height);
+		gvnc_update(gvnc, x, y, width, height);
 		break;
 	case GVNC_ENCODING_DESKTOP_RESIZE:
 		gvnc_resize(gvnc, width, height);
@@ -1995,8 +2001,6 @@ static void gvnc_framebuffer_update(struct gvnc *gvnc, int32_t etype,
 		gvnc->has_error = TRUE;
 		break;
 	}
-
-	gvnc_update(gvnc, x, y, width, height);
 }
 
 gboolean gvnc_server_message(struct gvnc *gvnc)
-- 
1.5.6






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]