diff options
author | Ulrich Sibiller <uli42@gmx.de> | 2020-09-20 16:45:51 +0200 |
---|---|---|
committer | Ulrich Sibiller <uli42@gmx.de> | 2021-06-08 21:16:37 +0200 |
commit | 2742fde0043d2690c3c7b22f137679d0b91dac6c (patch) | |
tree | 0ec22729bf1c721bc24c66351aaf4c7da9429232 /nx-X11/programs | |
parent | 32e194d460d82313706c72110652782e6c26b872 (diff) | |
download | nx-libs-2742fde0043d2690c3c7b22f137679d0b91dac6c.tar.gz nx-libs-2742fde0043d2690c3c7b22f137679d0b91dac6c.tar.bz2 nx-libs-2742fde0043d2690c3c7b22f137679d0b91dac6c.zip |
Clipboard.c: improve explanations/FIXMEs
Diffstat (limited to 'nx-X11/programs')
-rw-r--r-- | nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index a72449633..a4f61ef19 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -923,12 +923,18 @@ void nxagentHandleSelectionRequestFromXServer(XEvent *X) int i = nxagentFindLastSelectionOwnerIndex(X->xselectionrequest.selection); if (i < nxagentMaxSelections) { +#if 0 if (lastClientWindowPtr != NULL && IS_INTERNAL_OWNER(i)) { /* * Request the real X server to transfer the selection content * to the NX_CUT_BUFFER_SERVER property of the serverWindow. * FIXME: document how we can end up here + * + * It looks like this is only reached when the real X server is + * on Windows. I suspect that this is connected to the windows X + * server (VcXSrv in my test) pushing PRIMARY or CLIPBOARD + * content to the Windows clipboard whenever they change. */ XConvertSelection(nxagentDisplay, CurrentSelections[i].selection, X->xselectionrequest.target, serverTransToAgentProperty, @@ -949,6 +955,7 @@ void nxagentHandleSelectionRequestFromXServer(XEvent *X) SAFE_XFree(strProperty); } else +#endif { /* * if one of our clients owns the selection we ask it to copy @@ -1683,6 +1690,7 @@ static void setSelectionOwner(Selection *pSelection) /* * we are in the process of communicating back and forth between * real X server and nxagent's clients - let's not disturb + * FIXME: by continuing after the warning were ARE disturbing! */ fprintf (stderr, "%s: WARNING! Requestor window [0x%x] already set.\n", __func__, lastServerRequestor); @@ -1804,6 +1812,7 @@ int nxagentConvertSelection(ClientPtr client, WindowPtr pWin, Atom selection, "notifying failure to client %s\n", __func__, nxagentClientInfoString(client)); #endif + /* notify the waiting client of failure */ endTransfer(SELECTION_FAULT); } else @@ -1999,7 +2008,7 @@ int nxagentConvertSelection(ClientPtr client, WindowPtr pWin, Atom selection, XConvertSelection(nxagentDisplay, selection, t, p, serverWindow, CurrentTime); - /* FIXME: check returncode of XConvertSelection */ + /* FIXME: check result of XConvertSelection? */ #ifdef DEBUG fprintf(stderr, "%s: Sent XConvertSelection with target [%s], property [%s]\n", __func__, tstr, pstr); |