]> source.dussan.org Git - tigervnc.git/commitdiff
Fixed a problem of not using XReadDisplay extension for parts of
authorConstantin Kaplinsky <const@tightvnc.com>
Mon, 6 Mar 2006 05:12:32 +0000 (05:12 +0000)
committerConstantin Kaplinsky <const@tightvnc.com>
Mon, 6 Mar 2006 05:12:32 +0000 (05:12 +0000)
images, under IRIX.

git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@501 3789f03b-4d11-0410-bbf8-ca57d06f2519

x0vncserver/Image.cxx

index 36b2de440d8b974e9696c397e55ba2156ec00f7a..475cee19ee283342df63291c0cc59556ca40604f 100644 (file)
@@ -417,23 +417,22 @@ IrixOverlayShmImage::~IrixOverlayShmImage()
 
 void IrixOverlayShmImage::get(Window wnd, int x, int y)
 {
-    XRectangle rect; 
-    unsigned long hints = XRD_TRANSPARENT | XRD_READ_POINTER;
-
-    rect.x = x;
-    rect.y = y;
-    rect.width = xim->width;
-    rect.height = xim->height;
-
-    XShmReadDisplayRects(dpy, wnd,
-                         &rect, 1, readDisplayBuf, -x, -y,
-                         hints, &hints);
+  get(wnd, x, y, xim->width, xim->height);
 }
 
 void IrixOverlayShmImage::get(Window wnd, int x, int y, int w, int h)
 {
-  // FIXME: Use XReadDisplay extension here as well!
-  XGetSubImage(dpy, wnd, x, y, w, h, AllPlanes, ZPixmap, xim, 0, 0);
+  XRectangle rect;
+  unsigned long hints = XRD_TRANSPARENT | XRD_READ_POINTER;
+
+  rect.x = x;
+  rect.y = y;
+  rect.width = w;
+  rect.height = h;
+
+  XShmReadDisplayRects(dpy, wnd,
+                       &rect, 1, readDisplayBuf, -x, -y,
+                       hints, &hints);
 }
 
 #endif // HAVE_READDISPLAY