Mercurial > pidgin.yaz
comparison gtk/gtkblist.c @ 14560:16bba6d02c2a
[gaim-migrate @ 17283]
Only color the group name when not selected
committer: Tailor Script <tailor@pidgin.im>
author | Sean Egan <seanegan@gmail.com> |
---|---|
date | Fri, 15 Sep 2006 17:10:37 +0000 |
parents | 776975f2c550 |
children | 3ff55ec8203a |
comparison
equal
deleted
inserted
replaced
14559:fe9222bf8b1d | 14560:16bba6d02c2a |
---|---|
4347 { | 4347 { |
4348 GaimGroup *group; | 4348 GaimGroup *group; |
4349 int count; | 4349 int count; |
4350 gboolean show = FALSE; | 4350 gboolean show = FALSE; |
4351 GaimBlistNode* gnode; | 4351 GaimBlistNode* gnode; |
4352 gboolean selected = gtkblist ? (gtkblist->selected_node == node) : FALSE; | |
4352 | 4353 |
4353 g_return_if_fail(node != NULL); | 4354 g_return_if_fail(node != NULL); |
4354 | 4355 |
4355 if (GAIM_BLIST_NODE_IS_GROUP(node)) | 4356 if (GAIM_BLIST_NODE_IS_GROUP(node)) |
4356 gnode = node; | 4357 gnode = node; |
4391 path = gtk_tree_model_get_path(GTK_TREE_MODEL(gtkblist->treemodel), &iter); | 4392 path = gtk_tree_model_get_path(GTK_TREE_MODEL(gtkblist->treemodel), &iter); |
4392 expanded = gtk_tree_view_row_expanded(GTK_TREE_VIEW(gtkblist->treeview), path); | 4393 expanded = gtk_tree_view_row_expanded(GTK_TREE_VIEW(gtkblist->treeview), path); |
4393 gtk_tree_path_free(path); | 4394 gtk_tree_path_free(path); |
4394 | 4395 |
4395 esc = g_markup_escape_text(group->name, -1); | 4396 esc = g_markup_escape_text(group->name, -1); |
4396 mark = g_strdup_printf("<span color='#%02x%02x%02x'><span weight='bold'>%s</span> (%d/%d)</span>", | 4397 if (selected) |
4397 textcolor.red>>8, textcolor.green>>8, textcolor.blue>>8, | 4398 mark = g_strdup_printf("<span weight='bold'>%s</span> (%d/%d)", |
4398 esc, gaim_blist_get_group_online_count(group), | 4399 esc, gaim_blist_get_group_online_count(group), |
4399 gaim_blist_get_group_size(group, FALSE)); | 4400 gaim_blist_get_group_size(group, FALSE)); |
4401 else | |
4402 mark = g_strdup_printf("<span color='#%02x%02x%02x'><span weight='bold'>%s</span> (%d/%d)</span>", | |
4403 textcolor.red>>8, textcolor.green>>8, textcolor.blue>>8, | |
4404 esc, gaim_blist_get_group_online_count(group), | |
4405 gaim_blist_get_group_size(group, FALSE)); | |
4406 | |
4400 g_free(esc); | 4407 g_free(esc); |
4401 | 4408 |
4402 gtk_tree_store_set(gtkblist->treemodel, &iter, | 4409 gtk_tree_store_set(gtkblist->treemodel, &iter, |
4403 STATUS_ICON_VISIBLE_COLUMN, FALSE, | 4410 STATUS_ICON_VISIBLE_COLUMN, FALSE, |
4404 STATUS_ICON_COLUMN, NULL, | 4411 STATUS_ICON_COLUMN, NULL, |