/soc/2015/koosha/main: 9681c39416ec: XEP-0308: update sending si...

Koosha Khajehmoogahi <[email protected]>
Newsgroups gmane.comp.gnome.gaim.cvs
Message-ID <[email protected]>
Changeset: 9681c39416ec1ea80704661cbf1e0c5f7d66bde4
Author:	 Koosha Khajehmoogahi <[email protected]>
Date:	 2015-07-10 17:25 +0200
Branch:	 default
URL: https://hg.pidgin.im/soc/2015/koosha/main/rev/9681c39416ec

Description:

XEP-0308: update sending side conversation window in Pidgin

diffstat:

 libpurple/protocols/jabber/jabber.c |  6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diffs (23 lines):

diff --git a/libpurple/protocols/jabber/jabber.c b/libpurple/protocols/jabber/jabber.c
--- a/libpurple/protocols/jabber/jabber.c
+++ b/libpurple/protocols/jabber/jabber.c
@@ -3205,6 +3205,7 @@ jabber_cmd_replace(PurpleConversation *c
 	PurpleAccount *account;
 	PurpleBuddy *buddy;
 	PurpleConnection *conn;
+	PurpleMessageFlags flags = 0;
 	PurpleXmlNode *body, *replace, *msg;
 	JabberStream *js;
 	JabberBuddy *jb;
@@ -3257,6 +3258,11 @@ jabber_cmd_replace(PurpleConversation *c
 	jabber_send(js, msg);
 	purple_xmlnode_free(msg);
 
+	/* TODO: update the last message in history as well */
+	flags |= PURPLE_MESSAGE_SEND;
+	flags |= PURPLE_MESSAGE_REPLACE_LAST;
+	purple_conversation_write_system_message(conv, args[0], flags);
+
 	purple_signal_emit(purple_connection_get_protocol(conn), "jabber-replacing-message",
 			conn, last_id, args[0]);
 

_______________________________________________
Commits mailing list
[email protected]
https://pidgin.im/cgi-bin/mailman/listinfo/commits
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.