[empathy: 9/22] adium: set x-empathy-message-id class in messageStyles



commit bd0755be84f285e48272fb0b7ac154bad4be0902
Author: Jonny Lamb <jonnylamb gnome org>
Date:   Fri May 13 11:22:22 2011 +0100

    adium: set x-empathy-message-id class in messageStyles
    
    Signed-off-by: Jonny Lamb <jonnylamb gnome org>

 libempathy-gtk/empathy-theme-adium.c |   11 +++++++++++
 1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/libempathy-gtk/empathy-theme-adium.c b/libempathy-gtk/empathy-theme-adium.c
index 06410c5..c947c28 100644
--- a/libempathy-gtk/empathy-theme-adium.c
+++ b/libempathy-gtk/empathy-theme-adium.c
@@ -638,6 +638,7 @@ theme_adium_append_message (EmpathyChatView *view,
 	EmpathyThemeAdium     *theme = EMPATHY_THEME_ADIUM (view);
 	EmpathyThemeAdiumPriv *priv = GET_PRIV (theme);
 	EmpathyContact        *sender;
+	TpMessage             *tp_msg;
 	TpAccount             *account;
 	gchar                 *body_escaped;
 	const gchar           *body;
@@ -759,6 +760,16 @@ theme_adium_append_message (EmpathyChatView *view,
 	 * %status% - See %status% in theme_adium_append_html ()
 	 */
 
+	/* x-empathy-message-id-* */
+	tp_msg = empathy_message_get_tp_message (msg);
+	if (tp_msg != NULL) {
+		gchar *tmp = tp_escape_as_identifier (
+		    tp_message_get_token (tp_msg));
+		g_string_append_printf (message_classes,
+		    " x-empathy-message-id-%s", tmp);
+		g_free (tmp);
+	}
+
 	/* Define javascript function to use */
 	if (consecutive) {
 		func = priv->allow_scrolling ? "appendNextMessage" : "appendNextMessageNoScroll";



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]