Changeset 3231485


Ignore:
Timestamp:
2011-10-01T14:57:48Z (13 years ago)
Author:
unknown <pesco@…>
Branches:
master
Children:
e67e513
Parents:
fb11647a
Message:

make libotr messages associated with a user appear from that nick

File:
1 edited

Legend:

Unmodified
Added
Removed
  • otr.c

    rfb11647a r3231485  
    614614        char *msg = g_strdup(message);
    615615        irc_t *irc = ic->bee->ui_data;
     616        irc_user_t *u = peeruser(irc, username, protocol);
    616617
    617618        strip_html(msg);
    618         irc_usermsg(irc, "otr: %s", msg);
     619        if(u) {
     620                /* display message like it came from this particular user */
     621                bee_irc_msg_from_user(u, msg, 0 /* sent_at */);
     622        } else {
     623                irc_usermsg(irc, "otr: %s", msg);
     624        }
    619625
    620626        g_free(msg);
     
    18451851        }
    18461852}
     1853
     1854/* vim: noet ts=4 sw=4 */
Note: See TracChangeset for help on using the changeset viewer.