pidgin: 47a1e727: Make idle and offline buddy names and th...
markdoliner at pidgin.im
markdoliner at pidgin.im
Sat Aug 22 15:40:37 EDT 2009
-----------------------------------------------------------------
Revision: 47a1e727a78b5fd20a13a36ac69f73845d44d101
Ancestor: dbaa86f7e1344923764e572cebfb30ce7c53ee80
Author: markdoliner at pidgin.im
Date: 2009-08-22T19:35:02
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/47a1e727a78b5fd20a13a36ac69f73845d44d101
Modified files:
pidgin/gtkblist.c
ChangeLog:
Make idle and offline buddy names and the idle time in the small list grey
in the buddy list when not using a theme, and default offline buddies to
grey when using a theme that does not specify a color for offline buddies
Fixes #9947
-------------- next part --------------
============================================================
--- pidgin/gtkblist.c 62099ac72bbeddb9a5cc1bb7894a66dcd9a9c859
+++ pidgin/gtkblist.c b535b055d81462aecdc0fb32c6e6c7000cedd0c3
@@ -4148,6 +4148,7 @@ pidgin_blist_get_name_markup(PurpleBuddy
name_color = "dim grey";
} else if (!purple_presence_is_online(presence)) {
namefont = pidgin_blist_theme_get_offline_text_info(theme);
+ name_color = "dim grey";
statusfont = pidgin_blist_theme_get_status_text_info(theme);
} else if (purple_presence_is_available(presence)) {
namefont = pidgin_blist_theme_get_online_text_info(theme);
@@ -4156,6 +4157,13 @@ pidgin_blist_get_name_markup(PurpleBuddy
namefont = pidgin_blist_theme_get_away_text_info(theme);
statusfont = pidgin_blist_theme_get_status_text_info(theme);
}
+ } else {
+ if (!selected
+ && (purple_presence_is_idle(presence)
+ || !purple_presence_is_online(presence)))
+ {
+ name_color = "dim grey";
+ }
}
name_color = theme_font_get_color_default(namefont, name_color);
@@ -6405,10 +6413,13 @@ static void buddy_node(PurpleBuddy *budd
ihrs = (t - idle_secs) / 3600;
imin = ((t - idle_secs) / 60) % 60;
- if (!selected && theme != NULL && (pair = pidgin_blist_theme_get_idle_text_info(theme)) != NULL)
+ if (selected)
+ textcolor = NULL;
+ else if (theme != NULL && (pair = pidgin_blist_theme_get_idle_text_info(theme)) != NULL)
textcolor = pidgin_theme_font_get_color_describe(pair);
else
- textcolor = NULL;
+ /* If no theme them default to making idle buddy names grey */
+ textcolor = "dim grey";
if (textcolor) {
idle = g_strdup_printf("<span color='%s' font_desc='%s'>%d:%02d</span>",
More information about the Commits
mailing list