Rename kill ops
parent
b08c2d03ef
commit
3cd830681e
4
chat.h
4
chat.h
|
@ -151,8 +151,8 @@ enum Edit {
|
||||||
EditNext,
|
EditNext,
|
||||||
EditPrevWord,
|
EditPrevWord,
|
||||||
EditNextWord,
|
EditNextWord,
|
||||||
EditKillPrev,
|
EditDeleteHead,
|
||||||
EditKillNext,
|
EditDeleteTail,
|
||||||
EditDeletePrev,
|
EditDeletePrev,
|
||||||
EditDeleteNext,
|
EditDeleteNext,
|
||||||
EditInsert,
|
EditInsert,
|
||||||
|
|
4
edit.c
4
edit.c
|
@ -148,8 +148,8 @@ void edit(size_t id, enum Edit op, wchar_t ch) {
|
||||||
|
|
||||||
break; case EditDeletePrev: if (pos) delete(--pos, 1);
|
break; case EditDeletePrev: if (pos) delete(--pos, 1);
|
||||||
break; case EditDeleteNext: delete(pos, 1);
|
break; case EditDeleteNext: delete(pos, 1);
|
||||||
break; case EditKillPrev: delete(0, pos); pos = 0;
|
break; case EditDeleteHead: delete(0, pos); pos = 0;
|
||||||
break; case EditKillNext: delete(pos, len - pos);
|
break; case EditDeleteTail: delete(pos, len - pos);
|
||||||
|
|
||||||
break; case EditInsert: {
|
break; case EditInsert: {
|
||||||
reserve(pos, 1);
|
reserve(pos, 1);
|
||||||
|
|
4
ui.c
4
ui.c
|
@ -656,9 +656,9 @@ static void keyCtrl(wchar_t ch) {
|
||||||
break; case L'H': edit(id, EditDeletePrev, 0);
|
break; case L'H': edit(id, EditDeletePrev, 0);
|
||||||
break; case L'I': edit(id, EditComplete, 0);
|
break; case L'I': edit(id, EditComplete, 0);
|
||||||
break; case L'J': edit(id, EditEnter, 0);
|
break; case L'J': edit(id, EditEnter, 0);
|
||||||
break; case L'K': edit(id, EditKillNext, 0);
|
break; case L'K': edit(id, EditDeleteTail, 0);
|
||||||
break; case L'L': clearok(curscr, true);
|
break; case L'L': clearok(curscr, true);
|
||||||
break; case L'U': edit(id, EditKillPrev, 0);
|
break; case L'U': edit(id, EditDeleteHead, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue