More support for multiple identities.

This commit is contained in:
Håvard Pettersson 2014-09-07 03:04:42 +02:00
parent 76d07ed4f6
commit b60ac98a3e
14 changed files with 529 additions and 344 deletions

View file

@ -5,30 +5,37 @@
#include <tox/tox.h>
struct t_tox_chat
struct t_tox_weechat_chat
{
struct t_gui_buffer *buffer;
int32_t friend_number;
// linked list pointers
struct t_tox_chat *next;
struct t_tox_chat *prev;
struct t_tox_weechat_identity *identity;
struct t_tox_weechat_chat *next_chat;
struct t_tox_weechat_chat *prev_chat;
};
struct t_tox_chat *tox_weechat_get_friend_chat(int32_t friend_number);
struct t_tox_chat *tox_weechat_get_existing_friend_chat(int32_t friend_number);
struct t_tox_chat *tox_weechat_get_chat_for_buffer(struct t_gui_buffer *target_buffer);
struct t_tox_weechat_chat *
tox_weechat_get_friend_chat(struct t_tox_weechat_identity *identity,
int32_t friend_number);
struct t_tox_chat *tox_weechat_get_first_chat();
struct t_tox_weechat_chat *
tox_weechat_get_existing_friend_chat(struct t_tox_weechat_identity *identity,
int32_t friend_number);
void tox_weechat_chat_print_message(struct t_tox_chat *chat,
struct t_tox_weechat_chat *
tox_weechat_get_chat_for_buffer(struct t_gui_buffer *target_buffer);
void tox_weechat_chat_print_message(struct t_tox_weechat_chat *chat,
const char *sender,
const char *message);
void tox_weechat_chat_print_action(struct t_tox_chat *chat,
void tox_weechat_chat_print_action(struct t_tox_weechat_chat *chat,
const char *sender,
const char *message);
void tox_weechat_chat_refresh(struct t_tox_chat *chat);
void tox_weechat_chat_refresh(struct t_tox_weechat_chat *chat);
#endif // TOX_WEECHAT_CHATS_H