Mercurial > hg
comparison mcabber/src/jabglue.c @ 560:64cb4de94972
Better topic attribution
Better topic attribution, when getting history from the server.
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Thu, 01 Dec 2005 23:54:22 +0100 |
parents | 448e299e45da |
children | 7fc678ac3bc6 |
comparison
equal
deleted
inserted
replaced
559:4eb579399613 | 560:64cb4de94972 |
---|---|
1249 // Set the new topic | 1249 // Set the new topic |
1250 roombuddy = roster_find(s, jidsearch, 0); | 1250 roombuddy = roster_find(s, jidsearch, 0); |
1251 if (roombuddy) | 1251 if (roombuddy) |
1252 buddy_settopic(roombuddy->data, subj_noutf8); | 1252 buddy_settopic(roombuddy->data, subj_noutf8); |
1253 // Display inside the room window | 1253 // Display inside the room window |
1254 mbuf = g_strdup_printf("%s has set the topic to: %s", r, | 1254 if (r == s) { |
1255 (subj_noutf8 ? subj_noutf8 : "(?)")); | 1255 // No specific resource (this is certainly history) |
1256 mbuf = g_strdup_printf("The topic has been set to: %s", | |
1257 (subj_noutf8 ? subj_noutf8 : "(?)")); | |
1258 } else { | |
1259 mbuf = g_strdup_printf("%s has set the topic to: %s", r, | |
1260 (subj_noutf8 ? subj_noutf8 : "(?)")); | |
1261 } | |
1256 scr_WriteIncomingMessage(s, mbuf, 0, | 1262 scr_WriteIncomingMessage(s, mbuf, 0, |
1257 HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG); | 1263 HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG); |
1258 if (settings_opt_get_int("log_muc_conf")) | 1264 if (settings_opt_get_int("log_muc_conf")) |
1259 hlog_write_message(s, 0, FALSE, mbuf); | 1265 hlog_write_message(s, 0, FALSE, mbuf); |
1260 if (subj_noutf8) g_free(subj_noutf8); | 1266 if (subj_noutf8) g_free(subj_noutf8); |