summaryrefslogtreecommitdiff
path: root/src/chat.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/chat.c')
-rw-r--r--src/chat.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/src/chat.c b/src/chat.c
index 1b4bd48..c4b67b2 100644
--- a/src/chat.c
+++ b/src/chat.c
@@ -25,6 +25,9 @@
#include "chat.h"
#include "application.h"
+#include "ui/accounts.h"
+
+UI_ACCOUNTS_Handle accounts;
int lc = 0;
@@ -33,7 +36,7 @@ _chat_message(UNUSED void *cls,
UNUSED struct GNUNET_CHAT_Context *context,
UNUSED const struct GNUNET_CHAT_Message *message)
{
- //MESSENGER_Application *app = cls;
+ // MESSENGER_Application *app = cls;
enum GNUNET_CHAT_MessageKind kind = GNUNET_CHAT_message_get_kind(
message
@@ -46,9 +49,12 @@ _chat_message(UNUSED void *cls,
}
static void
-_chat_refresh(UNUSED MESSENGER_Application *app)
+_chat_refresh(MESSENGER_Application *app)
{
// TODO
+
+ accounts.window = stdscr;
+ accounts_print(&accounts, app);
}
static int
@@ -64,6 +70,8 @@ _chat_event(MESSENGER_Application *app,
move(lc++, 0);
printw("KEY %d", key);
+ accounts_event(&accounts, app, key);
+
refresh:
_chat_refresh(app);
return 0;