Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Clipboard.c: fix: use XlibWindow instead of Window | Ulrich Sibiller | 2021-06-20 | 1 | -17/+17 |
| | |||||
* | Clipboard.c: fix type in status output | Ulrich Sibiller | 2021-06-20 | 1 | -2/+2 |
| | |||||
* | Clipboard.c: avoid superflous atom conversion | Ulrich Sibiller | 2021-06-20 | 1 | -6/+4 |
| | |||||
* | Atoms.c: ensure to always return a valid string... | Ulrich Sibiller | 2021-06-20 | 2 | -53/+52 |
| | | | | | | ... by providing NameFor(Int|Rem)Atom() macros This way we do not have to validate it at various other places. | ||||
* | Clipboard.c: make use of the new helpers from Atoms.c | Ulrich Sibiller | 2021-06-20 | 1 | -113/+50 |
| | | | | | This saves us from having to create intermediate strings and Xfreeing them again. Which can easily be forgotten, producing memleaks. | ||||
* | Atoms.c: add helper to easily print Atom names in debugging | Ulrich Sibiller | 2021-06-20 | 2 | -2/+62 |
| | |||||
* | Clipboard.c: compact clipboard status output | Ulrich Sibiller | 2021-06-20 | 1 | -45/+48 |
| | | | | require less lines | ||||
* | Clipboard.c: fix comment position and init array pointer | Ulrich Sibiller | 2021-06-20 | 1 | -2/+3 |
| | |||||
* | Clipboard.c: drop clientCLIPBOARD | Ulrich Sibiller | 2021-06-20 | 1 | -14/+14 |
| | | | | read the value from the intSelAtoms array instead | ||||
* | Clipboard.c: move selection Atoms into separate arrays | Ulrich Sibiller | 2021-06-20 | 1 | -39/+49 |
| | | | | | They really only change on startup and reconnect. Also with this change we now only have internal Atoms in the LastSelectionOwner array. | ||||
* | Clipboard.c: rephrase FIXME | Ulrich Sibiller | 2021-06-20 | 1 | -5/+11 |
| | |||||
* | Clipboard.c: restructure request accumulation code | Ulrich Sibiller | 2021-06-20 | 1 | -17/+22 |
| | |||||
* | Clipboard.c: use for loops everywhere. | Ulrich Sibiller | 2021-06-20 | 1 | -10/+13 |
| | |||||
* | Clipboard.c: fix memleaks in DEBUG mode | Ulrich Sibiller | 2021-06-20 | 1 | -5/+15 |
| | |||||
* | Clipboard.c: split if clause | Ulrich Sibiller | 2021-06-20 | 1 | -3/+21 |
| | | | | this allows better error messages | ||||
* | Clipboard.c: remove superflous index determination | Ulrich Sibiller | 2021-06-20 | 1 | -88/+84 |
| | | | | we already have it at that stage | ||||
* | Clipboard.c: always print SelectionCallBackKind in debug output | Ulrich Sibiller | 2021-06-20 | 1 | -12/+26 |
| | |||||
* | Clipboard.c: mark self-initiated event | Ulrich Sibiller | 2021-06-20 | 1 | -0/+5 |
| | |||||
* | Clipboard.c: rename function to better reflect meaning | Ulrich Sibiller | 2021-06-20 | 3 | -20/+15 |
| | | | | Also improve Debug output. | ||||
* | Clipboard.c: have lastServer* per selection | Ulrich Sibiller | 2021-06-20 | 1 | -73/+110 |
| | | | | This will help in PRIMARY content appearing in CLIPBOARD and vice versa. | ||||
* | Clipboard.c: fix nxagentConvertSelection | Ulrich Sibiller | 2021-06-20 | 1 | -22/+24 |
| | | | | | | | - debug output was not printed at the beginning but later and was therefore missing sometimes - add comments/FIXMEs - re-enable failure notification for second call | ||||
* | Clipboard.c: improve debug/test messages | Ulrich Sibiller | 2021-06-20 | 1 | -4/+5 |
| | |||||
* | Clipboard.c: simplify nxagentHandleSelectionRequestFromXServer | Ulrich Sibiller | 2021-06-20 | 1 | -120/+107 |
| | | | | | | - remove redundant calls to nxagentFindLastSelectionOwnerIndex which reduce indentation level - scope improvements | ||||
* | Clipboard.c: use index everywhere | Ulrich Sibiller | 2021-06-20 | 1 | -88/+87 |
| | |||||
* | Clipboard.c: introduce translateLocalToRemote* helpers | Ulrich Sibiller | 2021-06-20 | 1 | -108/+90 |
| | | | | | This also unifies target handling to never use TEXT or COMPOUND_TEXT (despite announcing it) | ||||
* | Clipboard.c: rename selection fields to {int,rem}Selection | Ulrich Sibiller | 2021-06-20 | 1 | -52/+88 |
| | | | | This helps in avoiding storing the wrong value in a field. | ||||
* | Clipboard.c: reformat for better readability | Ulrich Sibiller | 2021-06-20 | 1 | -23/+23 |
| | |||||
* | Clipboard.c: improve function names once more | Ulrich Sibiller | 2021-06-20 | 3 | -39/+39 |
| | |||||
* | Clipboard.c: rework LastClient stuff to work _per selection_ | Ulrich Sibiller | 2021-06-20 | 3 | -232/+325 |
| | |||||
* | Clipboard.c: catch selection failure from real X server | Ulrich Sibiller | 2021-06-08 | 1 | -0/+8 |
| | |||||
* | Clipboard.c: do not set stage to new value if already set to that value | Ulrich Sibiller | 2021-06-08 | 1 | -0/+9 |
| | |||||
* | Clipboard.c: print times unsigned | Ulrich Sibiller | 2021-06-08 | 1 | -4/+4 |
| | | | | there are no negative times... | ||||
* | Clipboard.c: improve explanations/FIXMEs | Ulrich Sibiller | 2021-06-08 | 1 | -1/+10 |
| | |||||
* | Clipboard.c: improve debugging output | Ulrich Sibiller | 2021-06-08 | 1 | -20/+36 |
| | |||||
* | Clipboard.c: improve error message | Ulrich Sibiller | 2021-06-08 | 1 | -20/+37 |
| | | | | | | if we get an unexpected property print that as an error. Before we saw "unexpected stage" in that case which does not really help in debugging... | ||||
* | Clipboard.c: add/fix comments | Ulrich Sibiller | 2021-06-08 | 1 | -3/+6 |
| | |||||
* | Merge branch 'uli42-pr/various7' into 3.6.x | Mike Gabriel | 2021-06-08 | 31 | -399/+542 |
|\ | | | | | | | Attributes GH PR #1007: https://github.com/ArcticaProject/nx-libs/pull/1007 | ||||
| * | nxagent: add missing command line switches to usage text | Ulrich Sibiller | 2021-06-08 | 1 | -0/+4 |
| | | |||||
| * | Trap.h: fix type of traps | Ulrich Sibiller | 2021-06-08 | 1 | -13/+15 |
| | | | | | | | | They are Booleans for some time now but this change was missing in Trap.h | ||||
| * | nxagent: fix some variable types in Init | Ulrich Sibiller | 2021-06-08 | 2 | -3/+3 |
| | | |||||
| * | nxagent: make nxagentX2go a Boolean everywhere | Ulrich Sibiller | 2021-06-08 | 5 | -5/+5 |
| | | | | | | | | also correct ugly if formatting regarding nxagentX2go | ||||
| * | nxagent: make nxagentAlpha* Booleans | Ulrich Sibiller | 2021-06-08 | 5 | -10/+10 |
| | | |||||
| * | nxagent: treat enableBackingStore as Boolean | Ulrich Sibiller | 2021-06-08 | 2 | -4/+4 |
| | | | | | | | | Use TRUE and FALSE like dix does. | ||||
| * | nxagent: make nxagentCompositeEnable a Boolean | Ulrich Sibiller | 2021-06-08 | 5 | -11/+9 |
| | | | | | | | | there's no need for that variable to be tri-state | ||||
| * | Composite.c: fix comment | Ulrich Sibiller | 2021-06-08 | 1 | -3/+3 |
| | | |||||
| * | nxagent: add command line switch to enable composite | Ulrich Sibiller | 2021-06-08 | 5 | -7/+20 |
| | | | | | | | | We have it disabled by default but there hasn't been a way to enable it. | ||||
| * | Compext.c: fix comparisons of 16bit sequence numbers | Ulrich Sibiller | 2021-06-08 | 1 | -12/+12 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | rep->generic.sequenceNumber is of type CARD16 state->sequence is of type unsigned long Converting state->sequence to an int as it has been done since the first version of nxcomp I know of (1.3.0-18 from 2003) is wrong here because for numbers > INT_MAX this will result in a negative number, which, after applying the 16bit modulo, will not match rep->generic.sequenceNumber. Example with numbers: CARD16 c = 24565 unsigned long u = 3179110389 c % 65536 = 24565 u % 65536 = 24565 (int)(u) = -1115856907 (int)(u) % 65536 = -40971 -40971 will not match 24565 To fix this we need to ensure the number stays positive. We use CARD16 for this to match the type in the request which is a 16bit number. On my system CARD16 is unsigned short which is guaranteed to contain _at least_ the 0-65,535 range. As there is no upper limit of the range we cannot drop the modulo because we need this value to be 16bit and not more. Thanks to Norm Green for providing log after log until we could finally identify the reason for him seeing "Xlib: unexpected async reply (sequence 0x94b01439)!" when pasting stopped working. | ||||
| * | Compext.c: fix misleading error message | Ulrich Sibiller | 2021-06-08 | 1 | -5/+6 |
| | | | | | | | | | | An X reply contains a type which is X_Reply or X_Error. This is not an opcode which is used when installing the handler. | ||||
| * | Compext.c: print received vs expected sequence number | Ulrich Sibiller | 2021-06-08 | 1 | -0/+28 |
| | | | | | | | | Should help in debugging "unexpected async reply" problems | ||||
| * | Compext.c: document function return codes | Ulrich Sibiller | 2021-06-08 | 1 | -0/+64 |
| | |