diff options
author | Moon <moon@140774ce-b5e7-0310-ab8b-a85725594a96> | 2008-06-09 11:37:13 +0000 |
---|---|---|
committer | Moon <moon@140774ce-b5e7-0310-ab8b-a85725594a96> | 2008-06-09 11:37:13 +0000 |
commit | d85d3de6c965ce9041b06f926658f767a37bae82 (patch) | |
tree | ab32f7efae10ea9c06b002754cff7648f3cae0d2 /src/plugins/fs/status.c | |
parent | 419728885e356d6737c7d9deb27b04733bced228 (diff) | |
download | gnunet-gtk-d85d3de6c965ce9041b06f926658f767a37bae82.tar.gz gnunet-gtk-d85d3de6c965ce9041b06f926658f767a37bae82.zip |
replace 'Status' column with an icon
merge 'Name' and 'Type' (à la Nautilus)
Diffstat (limited to 'src/plugins/fs/status.c')
-rw-r--r-- | src/plugins/fs/status.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/plugins/fs/status.c b/src/plugins/fs/status.c index 1ce858d3..47f383e3 100644 --- a/src/plugins/fs/status.c +++ b/src/plugins/fs/status.c | |||
@@ -75,5 +75,29 @@ getStatusName (enum GNUNET_URITRACK_STATE state) | |||
75 | return ""; | 75 | return ""; |
76 | } | 76 | } |
77 | 77 | ||
78 | const GdkPixbuf * | ||
79 | getStatusLogo (enum GNUNET_URITRACK_STATE state) | ||
80 | { | ||
81 | if (state & (GNUNET_URITRACK_DIRECTORY_ADDED)) | ||
82 | return gtk_icon_theme_load_icon (gtk_icon_theme_get_default (), | ||
83 | GTK_STOCK_ADD, 16, 0, (GError **)NULL); | ||
84 | if (state & (GNUNET_URITRACK_INSERTED || GNUNET_URITRACK_INDEXED)) | ||
85 | return gtk_icon_theme_load_icon (gtk_icon_theme_get_default (), | ||
86 | GTK_STOCK_HOME, 16, 0, (GError **)NULL); | ||
87 | if ((state & GNUNET_URITRACK_DOWNLOAD_STARTED) && | ||
88 | (0 == (state & | ||
89 | (GNUNET_URITRACK_DOWNLOAD_COMPLETED | | ||
90 | GNUNET_URITRACK_DOWNLOAD_ABORTED)))) | ||
91 | return gtk_icon_theme_load_icon (gtk_icon_theme_get_default (), | ||
92 | GTK_STOCK_GO_DOWN, 16, 0, (GError **)NULL); | ||
93 | if (state & GNUNET_URITRACK_DOWNLOAD_COMPLETED) | ||
94 | return gtk_icon_theme_load_icon (gtk_icon_theme_get_default (), | ||
95 | GTK_STOCK_APPLY, 16, 0, (GError **)NULL); | ||
96 | if (state & GNUNET_URITRACK_DOWNLOAD_ABORTED) | ||
97 | return gtk_icon_theme_load_icon (gtk_icon_theme_get_default (), | ||
98 | GTK_STOCK_CANCEL, 16, 0, (GError **)NULL); | ||
99 | return NULL; | ||
100 | } | ||
101 | |||
78 | 102 | ||
79 | /* end of status.c */ | 103 | /* end of status.c */ |