Mercurial > pidgin.yaz
comparison libpurple/protocols/jabber/jabber.c @ 29825:b0e7b4daf465
Do not show "Mood: mood ()" when there is no text.
author | Richard Laager <rlaager@wiktel.com> |
---|---|
date | Sun, 16 Nov 2008 18:56:16 +0000 |
parents | a61c017d3a99 |
children | 37be968cd42c |
comparison
equal
deleted
inserted
replaced
29824:432d9176d054 | 29825:b0e7b4daf465 |
---|---|
1570 status = purple_presence_get_active_status(presence); | 1570 status = purple_presence_get_active_status(presence); |
1571 mood = purple_status_get_attr_string(status, "mood"); | 1571 mood = purple_status_get_attr_string(status, "mood"); |
1572 if(mood != NULL) { | 1572 if(mood != NULL) { |
1573 const char *moodtext; | 1573 const char *moodtext; |
1574 moodtext = purple_status_get_attr_string(status, "moodtext"); | 1574 moodtext = purple_status_get_attr_string(status, "moodtext"); |
1575 if(moodtext != NULL) { | 1575 if(moodtext && *moodtext) { |
1576 char *moodplustext = g_strdup_printf("%s (%s)", mood, moodtext); | 1576 char *moodplustext = g_strdup_printf("%s (%s)", mood, moodtext); |
1577 | 1577 |
1578 purple_notify_user_info_add_pair(user_info, _("Mood"), moodplustext); | 1578 purple_notify_user_info_add_pair(user_info, _("Mood"), moodplustext); |
1579 g_free(moodplustext); | 1579 g_free(moodplustext); |
1580 } else | 1580 } else |