From b82f44e3565b6670e816f4081076596d0ea0236b Mon Sep 17 00:00:00 2001 From: Ulrich Sibiller Date: Fri, 14 Feb 2020 00:28:59 +0100 Subject: nxagent: Add keystroke for dumping the current clipboard state --- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Keystroke.c') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index 73a5901f8..d6c659fec 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -102,6 +102,8 @@ char * nxagentSpecialKeystrokeNames[] = { "autograb", + "dump_clipboard", + NULL, }; @@ -142,6 +144,7 @@ struct nxagentSpecialKeystrokeMap default_map[] = { {KEYSTROKE_VIEWPORT_SCROLL_DOWN, ControlMask, True, XK_KP_Down}, {KEYSTROKE_REREAD_KEYSTROKES, ControlMask, True, XK_k}, {KEYSTROKE_AUTOGRAB, ControlMask, True, XK_g}, + {KEYSTROKE_DUMP_CLIPBOARD, ControlMask | ShiftMask, True, XK_c}, {KEYSTROKE_END_MARKER, 0, False, NoSymbol}, }; struct nxagentSpecialKeystrokeMap *map = default_map; @@ -715,6 +718,9 @@ Bool nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) case KEYSTROKE_AUTOGRAB: *result = doAutoGrab; break; + case KEYSTROKE_DUMP_CLIPBOARD: + *result = doDumpClipboard; + break; case KEYSTROKE_NOTHING: /* do nothing. difference to KEYSTROKE_IGNORE is the return value */ case KEYSTROKE_END_MARKER: /* just to make gcc STFU */ case KEYSTROKE_MAX: -- cgit v1.2.3