Mercurial > pidgin
diff src/protocols/irc/msgs.c @ 9518:6c24a6f07256
[gaim-migrate @ 10345]
" Updates irc and silc to pass the topic setter to
gaim_conv_chat_set_topic. Theres more code duplication
in here than I would like, but it's better than adding
another var and adding more conditionals.." --Gary Kramlich
committer: Tailor Script <tailor@pidgin.im>
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Mon, 12 Jul 2004 19:38:05 +0000 |
parents | f5c08be60098 |
children | 8b2451878e26 |
line wrap: on
line diff
--- a/src/protocols/irc/msgs.c Mon Jul 12 19:37:07 2004 +0000 +++ b/src/protocols/irc/msgs.c Mon Jul 12 19:38:05 2004 +0000 @@ -270,17 +270,19 @@ if (!convo) { gaim_debug(GAIM_DEBUG_ERROR, "irc", "Got a topic for %s, which doesn't exist\n", chan); } - gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, topic); + /* If this is an interactive update, print it out */ tmp = gaim_escape_html(topic); if (!strcmp(name, "topic")) { nick = irc_mask_nick(from); + gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), nick, topic); msg = g_strdup_printf(_("%s has changed the topic to: %s"), nick, tmp); g_free(nick); gaim_conv_chat_write(GAIM_CONV_CHAT(convo), from, msg, GAIM_MESSAGE_SYSTEM, time(NULL)); g_free(msg); } else { msg = g_strdup_printf(_("The topic for %s is: %s"), chan, tmp); + gaim_conv_chat_set_topic(GAIM_CONV_CHAT(convo), NULL, topic); gaim_conv_chat_write(GAIM_CONV_CHAT(convo), "", msg, GAIM_MESSAGE_SYSTEM, time(NULL)); g_free(msg); }