[BACK]Return to xterm-keys.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / tmux

Diff for /src/usr.bin/tmux/Attic/xterm-keys.c between version 1.16 and 1.17

version 1.16, 2015/08/30 15:43:40 version 1.17, 2015/11/12 11:05:34
Line 40 
Line 40 
  * We accept any but always output the latter (it comes first in the table).   * We accept any but always output the latter (it comes first in the table).
  */   */
   
 int     xterm_keys_match(const char *, const char *, size_t, size_t *, u_int *);  int     xterm_keys_match(const char *, const char *, size_t, size_t *,
 int     xterm_keys_modifiers(const char *, size_t, size_t *, u_int *);              key_code *);
   int     xterm_keys_modifiers(const char *, size_t, size_t *, key_code *);
   
 struct xterm_keys_entry {  struct xterm_keys_entry {
         int              key;          key_code         key;
         const char      *template;          const char      *template;
 };  };
   
Line 115 
Line 116 
  */   */
 int  int
 xterm_keys_match(const char *template, const char *buf, size_t len,  xterm_keys_match(const char *template, const char *buf, size_t len,
     size_t *size, u_int *modifiers)      size_t *size, key_code *modifiers)
 {  {
         size_t  pos;          size_t  pos;
         int     retval;          int     retval;
Line 148 
Line 149 
   
 /* Find modifiers from buffer. */  /* Find modifiers from buffer. */
 int  int
 xterm_keys_modifiers(const char *buf, size_t len, size_t *pos, u_int *modifiers)  xterm_keys_modifiers(const char *buf, size_t len, size_t *pos,
       key_code *modifiers)
 {  {
         u_int   flags;          u_int   flags;
   
Line 179 
Line 181 
  * key), -1 for not found, 1 for partial match.   * key), -1 for not found, 1 for partial match.
  */   */
 int  int
 xterm_keys_find(const char *buf, size_t len, size_t *size, int *key)  xterm_keys_find(const char *buf, size_t len, size_t *size, key_code *key)
 {  {
         const struct xterm_keys_entry   *entry;          const struct xterm_keys_entry   *entry;
         u_int                            i, modifiers;          u_int                            i;
         int                              matched;          int                              matched;
           key_code                         modifiers;
   
         for (i = 0; i < nitems(xterm_keys_table); i++) {          for (i = 0; i < nitems(xterm_keys_table); i++) {
                 entry = &xterm_keys_table[i];                  entry = &xterm_keys_table[i];
Line 201 
Line 204 
   
 /* Lookup a key number from the table. */  /* Lookup a key number from the table. */
 char *  char *
 xterm_keys_lookup(int key)  xterm_keys_lookup(key_code key)
 {  {
         const struct xterm_keys_entry   *entry;          const struct xterm_keys_entry   *entry;
         u_int                            i;          u_int                            i;
         int                              modifiers;          key_code                         modifiers;
         char                            *out;          char                            *out;
   
         modifiers = 1;          modifiers = 1;

Legend:
Removed from v.1.16  
changed lines
  Added in v.1.17