Mercurial > pidgin.yaz
changeset 20323:ee70ed741ada
applied changes from 61346ebfdbe38e90d131141a7fa41abeda7984c5
through 2ed39e287c8bc0502ecaf3b390fc0441ab160a99
author | Luke Schierer <lschiere@pidgin.im> |
---|---|
date | Fri, 19 Oct 2007 17:56:36 +0000 |
parents | aad0f10eb4dc |
children | b03f87862aba |
files | pidgin/gtkblist.c |
diffstat | 1 files changed, 19 insertions(+), 11 deletions(-) [+] |
line wrap: on
line diff
--- a/pidgin/gtkblist.c Fri Oct 19 17:53:35 2007 +0000 +++ b/pidgin/gtkblist.c Fri Oct 19 17:56:36 2007 +0000 @@ -3459,25 +3459,31 @@ else idletime = g_strdup(_("Idle")); - if (!selected) + if (!selected) { + g_free(text); text = g_strdup_printf("<span color='%s'>%s</span>\n" - "<span color='%s' size='smaller'>%s%s%s</span>", - dim_grey(), esc, dim_grey(), - idletime != NULL ? idletime : "", - (idletime != NULL && statustext != NULL) ? " - " : "", - statustext != NULL ? statustext : ""); + "<span color='%s' size='smaller'>%s%s%s</span>", + dim_grey(), esc, dim_grey(), + idletime != NULL ? idletime : "", + (idletime != NULL && statustext != NULL) ? " - " : "", + statustext != NULL ? statustext : ""); + } } - else if (!selected && !statustext) /* We handle selected text later */ + else if (!selected && !statustext) {/* We handle selected text later */ + g_free(text); text = g_strdup_printf("<span color='%s'>%s</span>", dim_grey(), esc); - else if (!selected && !text) + } else if (!selected && !text) { + g_free(text); text = g_strdup_printf("<span color='%s'>%s</span>\n" "<span color='%s' size='smaller'>%s</span>", dim_grey(), esc, dim_grey(), statustext != NULL ? statustext : ""); + } } else if (!PURPLE_BUDDY_IS_ONLINE(b)) { - if (!selected && !statustext) /* We handle selected text later */ + if (!selected && !statustext) {/* We handle selected text later */ + g_free(text); text = g_strdup_printf("<span color='%s'>%s</span>", dim_grey(), esc); - else if (!selected && !text) + } else if (!selected && !text) text = g_strdup_printf("<span color='%s'>%s</span>\n" "<span color='%s' size='smaller'>%s</span>", dim_grey(), esc, dim_grey(), @@ -3494,13 +3500,15 @@ } /* It is selected. */ - if ((selected && !text) || (selected && idletime)) + if ((selected && !text) || (selected && idletime)) { + g_free(text); text = g_strdup_printf("%s\n" "<span size='smaller'>%s%s%s</span>", esc, idletime != NULL ? idletime : "", (idletime != NULL && statustext != NULL) ? " - " : "", statustext != NULL ? statustext : ""); + } g_free(idletime); g_free(statustext);