From f0d98ac2f8171bf599279e486b136264dc3547a1 Mon Sep 17 00:00:00 2001 From: Art Cancro Date: Sun, 29 Feb 2004 06:12:52 +0000 Subject: [PATCH] * can add chat to iconbar --- webcit/iconbar.c | 40 +++++++++++++++++++++++++++++++----- webcit/paging.c | 5 ++++- webcit/static/chat-icon.gif | Bin 0 -> 1984 bytes 3 files changed, 39 insertions(+), 6 deletions(-) create mode 100644 webcit/static/chat-icon.gif diff --git a/webcit/iconbar.c b/webcit/iconbar.c index 664861f3e..717fd5c2f 100644 --- a/webcit/iconbar.c +++ b/webcit/iconbar.c @@ -48,6 +48,7 @@ void do_iconbar(void) { int ib_tasks = 0; /* Tasks icon */ int ib_rooms = 1; /* Rooms icon */ int ib_users = 1; /* Users icon */ + int ib_chat = 0; /* Chat icon */ int ib_advanced = 1; /* Advanced Options icon */ int ib_logoff = 1; /* Logoff button */ int ib_citadel = 1; /* 'Powered by Citadel' logo */ @@ -69,13 +70,12 @@ void do_iconbar(void) { if (!strcasecmp(key, "ib_tasks")) ib_tasks = atoi(value); if (!strcasecmp(key, "ib_rooms")) ib_rooms = atoi(value); if (!strcasecmp(key, "ib_users")) ib_users = atoi(value); + if (!strcasecmp(key, "ib_chat")) ib_chat = atoi(value); if (!strcasecmp(key, "ib_advanced")) ib_advanced = atoi(value); if (!strcasecmp(key, "ib_logoff")) ib_logoff = atoi(value); if (!strcasecmp(key, "ib_citadel")) ib_citadel = atoi(value); - } - output_headers(11); do_template("beginbox_nt"); @@ -197,6 +197,21 @@ void do_iconbar(void) { wprintf("\n"); } + if (ib_chat) { + wprintf("" + "" + ); + if (ib_displayas != IB_TEXTONLY) { + wprintf("
"); + } + if (ib_displayas != IB_PICONLY) { + wprintf("Chat
"); + } + wprintf("
\n"); + } + if (ib_advanced) { wprintf("" "" + "" + "" + "\" \"" + "" + "Chat
" + "Clicking this icon enters real-time chat mode " + "with other users in the same room." + "\n", + (ib_chat ? "CHECKED" : "") + ); + + wprintf("" "" "" @@ -443,7 +472,7 @@ void display_customize_iconbar(void) { (ib_advanced ? "CHECKED" : "") ); - wprintf("" + wprintf("" "" "" @@ -456,7 +485,7 @@ void display_customize_iconbar(void) { "\n", (ib_logoff ? "CHECKED" : "") ); - wprintf("" + wprintf("" "" "" @@ -495,6 +524,7 @@ void commit_iconbar(void) { "ib_tasks", "ib_rooms", "ib_users", + "ib_chat", "ib_advanced", "ib_logoff", "ib_citadel" diff --git a/webcit/paging.c b/webcit/paging.c index fc573cd62..0c13acedb 100644 --- a/webcit/paging.c +++ b/webcit/paging.c @@ -121,7 +121,9 @@ void do_chat(void) output_headers(1); wprintf("
" - "Real-time chat\n" + "" + "" + "Real-time chat\n" "
\n" "