mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
make all 8 X buffers available. no args uses the default buffer, giving 0-7
as an agument to in_paste_buffer specifies which buffer to use.
This commit is contained in:
parent
5f5060cbf0
commit
a45b78b622
1 changed files with 15 additions and 1 deletions
|
@ -130,7 +130,21 @@ in_paste_buffer_f (void)
|
|||
char *bytes, *p;
|
||||
int num_bytes;
|
||||
|
||||
bytes = XFetchBytes (x_disp, &num_bytes);
|
||||
if (Cmd_Argc () >= 2) {
|
||||
const char *val;
|
||||
char *end;
|
||||
int buffer;
|
||||
|
||||
val = Cmd_Argv (1);
|
||||
buffer = strtol (val, &end, 10);
|
||||
if (end == val || buffer < 0 || buffer > 7) {
|
||||
Sys_Printf ("invalid buffer number");
|
||||
return;
|
||||
}
|
||||
bytes = XFetchBuffer (x_disp, &num_bytes, buffer);
|
||||
} else {
|
||||
bytes = XFetchBytes (x_disp, &num_bytes);
|
||||
}
|
||||
if (!num_bytes)
|
||||
return;
|
||||
// get bytes to keys.c
|
||||
|
|
Loading…
Reference in a new issue