diff options
author | Pierre Ossman <ossman@cendio.se> | 2024-11-26 10:07:10 +0100 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2024-11-26 10:08:15 +0100 |
commit | 87b7bc496daa9072acc846d03ace116ced1e793e (patch) | |
tree | 1e2eba1bd36ab9793d1b64756daa3b7b883a3947 | |
parent | 44f67714bc53f33764da26d007b5dc4e8045473c (diff) | |
download | tigervnc-87b7bc496daa9072acc846d03ace116ced1e793e.tar.gz tigervnc-87b7bc496daa9072acc846d03ace116ced1e793e.zip |
Handle "no cursor", not just "empty cursor"
Some paths indicate a hidden cursor using NullCursor, and some (most)
use a valid cursor that just has no contents. Make sure we can handle
both cases.
-rw-r--r-- | unix/xserver/hw/vnc/vncHooks.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/unix/xserver/hw/vnc/vncHooks.c b/unix/xserver/hw/vnc/vncHooks.c index bb15591f..8384618a 100644 --- a/unix/xserver/hw/vnc/vncHooks.c +++ b/unix/xserver/hw/vnc/vncHooks.c @@ -560,11 +560,9 @@ static Bool vncHooksDisplayCursor(DeviceIntPtr pDev, ret = (*pScreen->DisplayCursor) (pDev, pScreen, cursor); - /* - * XXX DIX calls this function with NULL argument to remove cursor sprite from - * screen. Should we handle this in setCursor as well? - */ - if (cursor != NullCursor) { + if (cursor == NullCursor) { + vncSetCursorSprite(0, 0, 0, 0, NULL); + } else { int width, height; int hotX, hotY; |