All these return values from utf8_* are confusing, use an enum.

This commit is contained in:
nicm
2015-11-14 11:45:43 +00:00
parent f401791a56
commit 205d15e82d
7 changed files with 70 additions and 77 deletions

View File

@ -169,7 +169,7 @@ input_key(struct window_pane *wp, key_code key, struct mouse_event *m)
return;
}
if (key != KEYC_NONE && justkey > 0x7f && justkey < KEYC_BASE) {
if (utf8_split(justkey, &ud) != 0)
if (utf8_split(justkey, &ud) != UTF8_DONE)
return;
if (key & KEYC_ESCAPE)
bufferevent_write(wp->event, "\033", 1);