mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2026-04-27 12:31:54 +00:00
Left word jump (whoo that took long)
This commit is contained in:
parent
827d673667
commit
d68c420315
1 changed files with 25 additions and 1 deletions
|
|
@ -820,7 +820,31 @@ boolean CON_Responder(event_t *ev)
|
||||||
if (key == KEY_LEFTARROW)
|
if (key == KEY_LEFTARROW)
|
||||||
{
|
{
|
||||||
if (input_cur != 0)
|
if (input_cur != 0)
|
||||||
|
{
|
||||||
|
if (ctrldown)
|
||||||
|
{
|
||||||
|
int (*is)(int);
|
||||||
|
char *line;
|
||||||
|
int c;
|
||||||
|
line = inputlines[inputline];
|
||||||
|
c = line[--input_cur];
|
||||||
|
if (isspace(c))
|
||||||
|
is = isspace;
|
||||||
|
else if (ispunct(c))
|
||||||
|
is = ispunct;
|
||||||
|
else
|
||||||
|
is = isalnum;
|
||||||
|
c = (*is)(line[input_cur]);
|
||||||
|
while (input_cur > 0 &&
|
||||||
|
(*is)(line[input_cur - 1]) == c)
|
||||||
|
input_cur--;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
--input_cur;
|
--input_cur;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!shiftdown)
|
if (!shiftdown)
|
||||||
input_sel = input_cur;
|
input_sel = input_cur;
|
||||||
return true;
|
return true;
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue