diff options
Diffstat (limited to 'termkey-internal.h')
-rw-r--r-- | termkey-internal.h | 34 |
1 files changed, 17 insertions, 17 deletions
diff --git a/termkey-internal.h b/termkey-internal.h index dce83a6..8286c36 100644 --- a/termkey-internal.h +++ b/termkey-internal.h @@ -6,31 +6,31 @@ #include <stdint.h> #include <termios.h> -struct termkey_driver +struct TermKeyDriver { const char *name; - void *(*new_driver)(termkey_t *tk, const char *term); + void *(*new_driver)(TermKey *tk, const char *term); void (*free_driver)(void *info); - void (*start_driver)(termkey_t *tk, void *info); - void (*stop_driver)(termkey_t *tk, void *info); - termkey_result (*peekkey)(termkey_t *tk, void *info, termkey_key *key, int force, size_t *nbytes); + void (*start_driver)(TermKey *tk, void *info); + void (*stop_driver)(TermKey *tk, void *info); + TermKeyResult (*peekkey)(TermKey *tk, void *info, TermKeyKey *key, int force, size_t *nbytes); }; struct keyinfo { - termkey_type type; - termkey_keysym sym; + TermKeyType type; + TermKeySym sym; int modifier_mask; int modifier_set; }; -struct termkey_drivernode; -struct termkey_drivernode { - struct termkey_driver *driver; +struct TermKeyDriverNode; +struct TermKeyDriverNode { + struct TermKeyDriver *driver; void *info; - struct termkey_drivernode *next; + struct TermKeyDriverNode *next; }; -struct termkey { +struct _TermKey { int fd; int flags; unsigned char *buffer; @@ -51,17 +51,17 @@ struct termkey { // There are 32 C0 codes struct keyinfo c0[32]; - struct termkey_drivernode *drivers; + struct TermKeyDriverNode *drivers; // Now some "protected" methods for the driver to call but which we don't // want exported as real symbols in the library struct { - void (*emit_codepoint)(termkey_t *tk, long codepoint, termkey_key *key); - termkey_result (*peekkey_simple)(termkey_t *tk, termkey_key *key, int force, size_t *nbytes); + void (*emit_codepoint)(TermKey *tk, long codepoint, TermKeyKey *key); + TermKeyResult (*peekkey_simple)(TermKey *tk, TermKeyKey *key, int force, size_t *nbytes); } method; }; -extern struct termkey_driver termkey_driver_csi; -extern struct termkey_driver termkey_driver_ti; +extern struct TermKeyDriver termkey_driver_csi; +extern struct TermKeyDriver termkey_driver_ti; #endif |