summaryrefslogtreecommitdiffstats
path: root/cursor.c
diff options
context:
space:
mode:
authordscho <dscho>2001-09-24 07:30:50 +0000
committerdscho <dscho>2001-09-24 07:30:50 +0000
commitfa85c12aa9f552aeafca4099467439d4cf434b79 (patch)
treec17cbd30cbf8b62947be97fb7c2a4255adc2877f /cursor.c
parent1e83d9a5994e0e68497a136b719c9c1c53103f3c (diff)
downloadlibvncserver-fa85c12aa9f552aeafca4099467439d4cf434b79.zip
libvncserver-fa85c12aa9f552aeafca4099467439d4cf434b79.tar.gz
cursor changes
Diffstat (limited to 'cursor.c')
-rw-r--r--cursor.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/cursor.c b/cursor.c
index a47952a..d128254 100644
--- a/cursor.c
+++ b/cursor.c
@@ -495,6 +495,7 @@ void rfbUndrawCursor(rfbClientPtr cl)
rfbCursorPtr c=s->cursor;
int j,x1,x2,y1,y2,bpp=s->rfbServerFormat.bitsPerPixel/8,
rowstride=s->paddedWidthInBytes;
+ return;
if(!s->cursorIsDrawn)
return;
/* restore what is under the cursor */
@@ -512,6 +513,9 @@ void rfbUndrawCursor(rfbClientPtr cl)
memcpy(s->frameBuffer+(y1+j)*rowstride+x1*bpp,
s->underCursorBuffer+j*x2*bpp,
x2*bpp);
+
+ rfbMarkRectAsModified(s,x1,y1,x1+x2,y1+y2);
+ s->cursorIsDrawn = FALSE;
}
void rfbDrawCursor(rfbClientPtr cl)
@@ -521,6 +525,7 @@ void rfbDrawCursor(rfbClientPtr cl)
int i,j,x1,x2,y1,y2,i1,j1,bpp=s->rfbServerFormat.bitsPerPixel/8,
rowstride=s->paddedWidthInBytes,
bufSize=c->width*c->height*bpp,w=(c->width+7)/8;
+ return;
if(s->cursorIsDrawn)
rfbUndrawCursor(cl);
if(s->underCursorBufferLen<bufSize) {
@@ -555,6 +560,9 @@ void rfbDrawCursor(rfbClientPtr cl)
if((c->mask[(j+j1)*w+(i+i1)/8]<<((i+i1)&7))&0x80)
memcpy(s->frameBuffer+(j+y1)*rowstride+(i+x1)*bpp,
c->richSource+(j+j1)*c->width*bpp+(i+i1)*bpp,bpp);
+
+ rfbMarkRectAsModified(s,x1,y1,x1+x2,y1+y2);
+ s->cursorIsDrawn = TRUE;
}
void rfbPrintXCursor(rfbCursorPtr cursor)
OpenPOWER on IntegriCloud