Mercurial > pidgin
diff pidgin/gtkconv.c @ 32734:dfcad7368179
Replace the "%status%" variable in themes, though this only supports errors
right now.
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Sun, 04 Mar 2012 01:34:03 +0000 |
parents | 97bf6c9ef9ab |
children | 01741f87cc1e |
line wrap: on
line diff
--- a/pidgin/gtkconv.c Sun Mar 04 01:32:16 2012 +0000 +++ b/pidgin/gtkconv.c Sun Mar 04 01:34:03 2012 +0000 @@ -6250,6 +6250,14 @@ } else if (g_str_has_prefix(cur, "%messageDirection%")) { replace = purple_markup_is_rtl(message) ? "rtl" : "ltr"; + } else if (g_str_has_prefix(cur, "%status%")) { + GString *classes = g_string_new(NULL); + + if (flags & PURPLE_MESSAGE_ERROR) + g_string_append(classes, "error "); + + replace = freeval = g_string_free(classes, FALSE); + } else { cur++; continue;