Update of /cvsroot/gaim/gaim/src/protocols/sametime
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25616
Modified Files:
sametime.c
Log Message:
I don't use Sametime, so I don't know if this is correct, but I'm hoping to bring the tooltip a little more in line with the other protocols.
Index: sametime.c
===================================================================
RCS file: /cvsroot/gaim/gaim/src/protocols/sametime/sametime.c,v
retrieving revision 1.58
retrieving revision 1.59
diff -u -d -p -r1.58 -r1.59
--- sametime.c 19 Jan 2006 18:39:10 -0000 1.58
+++ sametime.c 19 Jan 2006 19:37:37 -0000 1.59
@@ -3179,28 +3179,33 @@ static char *mw_prpl_tooltip_text(GaimBu
struct mwAwareIdBlock idb = { mwAware_USER, b->name, NULL };
GString *str;
- const char *tmp;
+ const char *message;
+ char *tmp = NULL;
+ const char *status;
gc = b->account->gc;
pd = gc->proto_data;
str = g_string_new(NULL);
- tmp = mwServiceAware_getText(pd->srvc_aware, &idb);
- if(tmp) {
- tmp = g_markup_escape_text(tmp, -1);
- g_string_append_printf(str, _("\n<b>%s</b>: %s"), status_text(b), tmp);
- g_free((char *) tmp);
+ message = mwServiceAware_getText(pd->srvc_aware, &idb);
+ status = status_text(b);
- } else {
- g_string_append_printf(str, _("\n<b>Status</b>: %s"), status_text(b));
+ if(message != NULL && gaim_utf8_strcasecmp(status, message)) {
+ tmp = g_markup_escape_text(message, -1);
+ }
+
+ g_string_append_printf(str, _("\n<b>Status:</b> %s"), status);
+ if(tmp != NULL) {
+ g_string_append_printf(str, _("\n<b>Message:</b> %s"), tmp);
+ g_free(tmp);
}
if(full) {
tmp = user_supports_text(pd->srvc_aware, b->name);
if(tmp) {
- g_string_append_printf(str, _("\n<b>Supports</b>: %s"), tmp);
- g_free((char *) tmp);
+ g_string_append_printf(str, _("\n<b>Supports:</b> %s"), tmp);
+ g_free(tmp);
}
if(buddy_is_external(b)) {
|