From f5612b348bfa7d9524cecf30510ad04f701742c4 Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Tue, 3 Mar 2009 00:55:03 +0000 Subject: [PATCH] (trunk gtk) maybe compile a little better for Lacrocivous --- gtk/icons.c | 26 ++++++++++++++++++++++---- gtk/icons.h | 1 - 2 files changed, 22 insertions(+), 5 deletions(-) diff --git a/gtk/icons.c b/gtk/icons.c index cf46d9503..3b0da67a5 100644 --- a/gtk/icons.c +++ b/gtk/icons.c @@ -4,18 +4,17 @@ */ #include -#include -#include #include #include "icons.h" +#ifdef HAVE_GIO + +#include #define VOID_PIXBUF_KEY "void-pixbuf" - static GHashTable *static_strings = NULL; - static const char * get_static_string( const char *s ) { @@ -249,3 +248,22 @@ get_mime_type_from_filename( const char *file ) { return get_static_string( g_content_type_guess( file, NULL, 0, NULL )); } + +#else + +GdkPixbuf * +get_mime_type_icon( const char * mime_type, + GtkIconSize icon_size, + GtkWidget * for_widget ) +{ + return NULL; +} + + +const char * +get_mime_type_from_filename( const char *file ) +{ + return "uncertain"; +} + +#endif diff --git a/gtk/icons.h b/gtk/icons.h index cbdaf48ee..dd3ee507b 100644 --- a/gtk/icons.h +++ b/gtk/icons.h @@ -3,7 +3,6 @@ * "There is no problem for me, you can license my code under whatever licence you wish :)" */ - #ifndef ICONS_H #define ICONS_H