diff options
author | Alan Fitton <ajf@eth0.org.uk> | 2011-10-03 09:36:52 +0000 |
---|---|---|
committer | Alan Fitton <ajf@eth0.org.uk> | 2011-10-03 09:36:52 +0000 |
commit | 5ce226277955a7d1aa6f5d0e00acb2ee98041003 (patch) | |
tree | abe471016e38d7ea8d9559eee35afe0ef6687261 /src/trg-tree-view.c | |
parent | a9780439e066ea76d7b5aa6af66a8a539c59b0cf (diff) |
use an icon for file wanted/unwanted
Diffstat (limited to 'src/trg-tree-view.c')
-rw-r--r-- | src/trg-tree-view.c | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/src/trg-tree-view.c b/src/trg-tree-view.c index ede3989..7ee83a5 100644 --- a/src/trg-tree-view.c +++ b/src/trg-tree-view.c @@ -29,7 +29,6 @@ #include "trg-cell-renderer-ratio.h" #include "trg-cell-renderer-eta.h" #include "trg-cell-renderer-epoch.h" -#include "trg-cell-renderer-wanted.h" #include "trg-cell-renderer-priority.h" #include "trg-cell-renderer-numgteqthan.h" @@ -338,21 +337,21 @@ static void trg_tree_view_add_column_after(TrgTreeView * tv, desc->model_column, NULL); break; + case TRG_COLTYPE_ICON: + column = gtk_tree_view_column_new(); + renderer = gtk_cell_renderer_pixbuf_new(); + gtk_cell_renderer_set_alignment(GTK_CELL_RENDERER(renderer), 0.5f, 0.0); + gtk_tree_view_column_set_title(column, desc->header); + gtk_tree_view_column_pack_start(column, renderer, TRUE); + gtk_tree_view_column_set_attributes(column, renderer, "stock-id", + desc->model_column, NULL); + break; case TRG_COLTYPE_STOCKICONTEXT: column = trg_tree_view_icontext_column_new(desc, "stock-id"); break; - case TRG_COLTYPE_PIXBUFICONTEXT: + case TRG_COLTYPE_GICONTEXT: column = trg_tree_view_icontext_column_new(desc, "gicon"); break; - case TRG_COLTYPE_WANT: - renderer = trg_cell_renderer_wanted_new(); - column = - gtk_tree_view_column_new_with_attributes(desc->header, - renderer, - "wanted-value", - desc->model_column, - NULL); - break; case TRG_COLTYPE_PRIO: renderer = trg_cell_renderer_priority_new(); column = |