Mercurial > pidgin
diff src/protocols/msn/msn.c @ 8518:833dd756dcc3
[gaim-migrate @ 9257]
Patch by David Vermeille to add outgoing formatting support for MSN. I'd
like to thank him, as a number of people have attempted this patch and
ended up discouraged when told it would break core/UI split. David went
ahead and stuck through it, and we now have some decent support. I also
realized during this that we weren't processing certain incoming colors
correctly, so that's taken care of now.
committer: Tailor Script <tailor@pidgin.im>
author | Christian Hammond <chipx86@chipx86.com> |
---|---|
date | Sun, 28 Mar 2004 21:38:22 +0000 |
parents | 711927294475 |
children | 45e8c6cbd4a5 |
line wrap: on
line diff
--- a/src/protocols/msn/msn.c Sun Mar 28 19:53:43 2004 +0000 +++ b/src/protocols/msn/msn.c Sun Mar 28 21:38:22 2004 +0000 @@ -487,6 +487,7 @@ msn_http_session_init(session); gc->proto_data = session; + gc->flags |= GAIM_CONNECTION_HTML; gaim_connection_update_progress(gc, _("Connecting"), 0, MSN_CONNECT_STEPS); @@ -532,14 +533,20 @@ if (g_ascii_strcasecmp(who, gaim_account_get_username(account))) { MsnMessage *msg; MsnUser *user; + char *msgformat; + char *msgtext; user = msn_user_new(session, who, NULL); + msn_import_html(message, &msgformat, &msgtext); + msg = msn_message_new(); msn_message_set_receiver(msg, user); - msn_message_set_attr(msg, "X-MMS-IM-Format", - "FN=MS%20Sans%20Serif; EF=; CO=0; PF=0"); - msn_message_set_body(msg, message); + msn_message_set_attr(msg, "X-MMS-IM-Format", msgformat); + msn_message_set_body(msg, msgtext); + + g_free(msgformat); + g_free(msgtext); if (swboard != NULL) { if (!msn_switchboard_send_msg(swboard, msg))