diff options
Diffstat (limited to 'src/ui/window.h')
-rw-r--r-- | src/ui/window.h | 45 |
1 files changed, 37 insertions, 8 deletions
diff --git a/src/ui/window.h b/src/ui/window.h index ecf3a771..3c74b8da 100644 --- a/src/ui/window.h +++ b/src/ui/window.h @@ -57,7 +57,6 @@ #define PAD_SIZE 1000 typedef enum { - WIN_UNUSED, WIN_CONSOLE, WIN_CHAT, WIN_MUC, @@ -67,20 +66,50 @@ typedef enum { } win_type_t; typedef struct prof_win_t { - char *from; - char *chat_resource; + + win_type_t type; + WINDOW *win; - WINDOW *subwin; ProfBuff buffer; - win_type_t type; - gboolean is_otr; - gboolean is_trusted; + char *from; + char *chat_resource; int y_pos; - int sub_y_pos; int paged; + gboolean is_otr; + gboolean is_trusted; int unread; int history_shown; DataForm *form; + + union { + // WIN_CONSOLE + struct { + WINDOW *subwin; + int sub_y_pos; + } cons; + + // WIN_CHAT + struct { + } chat; + + // WIN_MUC + struct { + WINDOW *subwin; + int sub_y_pos; + } muc; + + // WIN_MUC_CONFIG + struct { + } conf; + + // WIN_PRIVATE + struct { + } priv; + + // WIN_XML + struct { + } xml; + } wins; } ProfWin; ProfWin* win_create(const char * const title, win_type_t type); |