=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/tmux.h,v retrieving revision 1.1040 retrieving revision 1.1041 diff -u -r1.1040 -r1.1041 --- src/usr.bin/tmux/tmux.h 2020/05/16 16:16:07 1.1040 +++ src/usr.bin/tmux/tmux.h 2020/05/16 16:20:59 1.1041 @@ -1,4 +1,4 @@ -/* $OpenBSD: tmux.h,v 1.1040 2020/05/16 16:16:07 nicm Exp $ */ +/* $OpenBSD: tmux.h,v 1.1041 2020/05/16 16:20:59 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott @@ -1508,6 +1508,14 @@ }; RB_HEAD(client_files, client_file); +/* Client window. */ +struct client_window { + u_int window; + struct window_pane *pane; + RB_ENTRY(client_window) entry; +}; +RB_HEAD(client_windows, client_window); + /* Client connection. */ typedef int (*prompt_input_cb)(struct client *, void *, const char *, int); typedef void (*prompt_free_cb)(void *); @@ -1521,6 +1529,8 @@ struct tmuxpeer *peer; struct cmdq_list *queue; + struct client_windows windows; + pid_t pid; int fd; struct event event; @@ -1585,6 +1595,7 @@ #define CLIENT_STARTSERVER 0x10000000 #define CLIENT_REDRAWPANES 0x20000000 #define CLIENT_NOFORK 0x40000000 +#define CLIENT_ACTIVEPANE 0x80000000ULL #define CLIENT_ALLREDRAWFLAGS \ (CLIENT_REDRAWWINDOW| \ CLIENT_REDRAWSTATUS| \ @@ -1600,7 +1611,7 @@ (CLIENT_DEAD| \ CLIENT_SUSPENDED| \ CLIENT_DETACHING) - int flags; + uint64_t flags; struct key_table *keytable; uint64_t redraw_panes; @@ -2299,6 +2310,7 @@ void printflike(1, 2) server_add_message(const char *, ...); /* server-client.c */ +RB_PROTOTYPE(client_windows, client_window, entry, server_client_window_cmp); u_int server_client_how_many(void); void server_client_set_overlay(struct client *, u_int, overlay_check_cb, overlay_mode_cb, overlay_draw_cb, overlay_key_cb, @@ -2321,6 +2333,9 @@ const char *server_client_get_cwd(struct client *, struct session *); void server_client_set_flags(struct client *, const char *); const char *server_client_get_flags(struct client *); +struct window_pane *server_client_get_pane(struct client *); +void server_client_set_pane(struct client *, struct window_pane *); +void server_client_remove_pane(struct window_pane *); /* server-fn.c */ void server_redraw_client(struct client *);