mcabber/mcabber/xmpp.c
changeset 1896 c5ab9cf3819a
parent 1895 7043542b3565
child 1899 decf94827efe
equal deleted inserted replaced
1895:7043542b3565 1896:c5ab9cf3819a
  1237       if (roombuddy)
  1237       if (roombuddy)
  1238         buddy_settopic(roombuddy->data, subj);
  1238         buddy_settopic(roombuddy->data, subj);
  1239       // Display inside the room window
  1239       // Display inside the room window
  1240       if (r == s) {
  1240       if (r == s) {
  1241         // No specific resource (this is certainly history)
  1241         // No specific resource (this is certainly history)
  1242         mbuf = g_strdup_printf("The topic has been set to: %s", subj);
  1242         if (*subj)
       
  1243           mbuf = g_strdup_printf("The topic has been set to: %s", subj);
       
  1244         else
       
  1245           mbuf = g_strdup_printf("The topic has been cleared");
  1243       } else {
  1246       } else {
  1244         mbuf = g_strdup_printf("%s has set the topic to: %s", r, subj);
  1247         if (*subj)
       
  1248           mbuf = g_strdup_printf("%s has set the topic to: %s", r, subj);
       
  1249         else
       
  1250           mbuf = g_strdup_printf("%s has cleared the topic", r);
  1245       }
  1251       }
  1246       scr_WriteIncomingMessage(s, mbuf, 0,
  1252       scr_WriteIncomingMessage(s, mbuf, 0,
  1247                                HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG, 0);
  1253                                HBB_PREFIX_INFO|HBB_PREFIX_NOFLAG, 0);
  1248       if (settings_opt_get_int("log_muc_conf"))
  1254       if (settings_opt_get_int("log_muc_conf"))
  1249         hlog_write_message(s, 0, -1, mbuf);
  1255         hlog_write_message(s, 0, -1, mbuf);