pty: move pty_input to pty_write
pty_write actually makes more sense as we are writing to the other end and not reading input. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This commit is contained in:
parent
c3d2ea3eb2
commit
cda62d3e60
@ -369,7 +369,7 @@ void kmscon_pty_close(struct kmscon_pty *pty)
|
|||||||
cb(pty, data);
|
cb(pty, data);
|
||||||
}
|
}
|
||||||
|
|
||||||
void kmscon_pty_input(struct kmscon_pty *pty, const char *u8, size_t len)
|
void kmscon_pty_write(struct kmscon_pty *pty, const char *u8, size_t len)
|
||||||
{
|
{
|
||||||
if (!pty || pty->fd < 0)
|
if (!pty || pty->fd < 0)
|
||||||
return;
|
return;
|
||||||
|
@ -61,7 +61,7 @@ int kmscon_pty_open(struct kmscon_pty *pty, struct kmscon_eloop *eloop,
|
|||||||
kmscon_pty_closed_cb closed_cb, void *data);
|
kmscon_pty_closed_cb closed_cb, void *data);
|
||||||
void kmscon_pty_close(struct kmscon_pty *pty);
|
void kmscon_pty_close(struct kmscon_pty *pty);
|
||||||
|
|
||||||
void kmscon_pty_input(struct kmscon_pty *pty, const char *u8, size_t len);
|
void kmscon_pty_write(struct kmscon_pty *pty, const char *u8, size_t len);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Call this whenever the size of the screen (rows or columns) changes. The
|
* Call this whenever the size of the screen (rows or columns) changes. The
|
||||||
|
@ -335,5 +335,5 @@ void kmscon_terminal_input(struct kmscon_terminal *term, kmscon_symbol_t ch)
|
|||||||
{
|
{
|
||||||
/* FIXME: UTF-8. */
|
/* FIXME: UTF-8. */
|
||||||
if (ch < 128)
|
if (ch < 128)
|
||||||
kmscon_pty_input(term->pty, (char *)&ch, 1);
|
kmscon_pty_write(term->pty, (char *)&ch, 1);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user