1
0
mirror of https://github.com/Tha14/toxic.git synced 2025-07-04 20:16:44 +02:00

replace prompt's PromptBuf struct with a ChatContext for compatibility

This commit is contained in:
Jfreegman
2014-03-24 07:37:52 -04:00
parent e5b6e0ad9f
commit a40b6b1b1b
5 changed files with 126 additions and 142 deletions

View File

@ -148,7 +148,6 @@ struct ToxWindow {
bool alert2;
ChatContext *chatwin;
PromptBuf *promptbuf;
StatusBar *stb;
WINDOW *popup;
@ -189,31 +188,17 @@ struct ChatContext {
struct history *hst;
struct chatlog *log;
uint8_t self_is_typing;
WINDOW *history;
WINDOW *linewin;
WINDOW *sidebar;
};
/* prompt window/buffer holder */
struct PromptBuf {
wchar_t line[MAX_STR_SIZE];
size_t pos;
size_t len;
/* specific for prompt */
bool at_bottom; /* true if line end is at bottom of window */
int orig_y; /* y axis point of line origin */
bool scroll; /* used for prompt window hack to determine when to scroll down */
wchar_t ln_history[MAX_LINE_HIST][MAX_STR_SIZE];
int hst_pos;
int hst_tot;
struct history *hst;
struct chatlog *log;
WINDOW *linewin;
};
/* Start file transfer code */