Use HAVE_GIO *everywhere* now

This commit is contained in:
Christian Dywan 2008-08-28 01:15:30 +02:00
parent be4038e555
commit b6ae63249b
4 changed files with 21 additions and 14 deletions

View file

@ -13,7 +13,7 @@
#if !GTK_CHECK_VERSION(2, 14, 0)
#if GLIB_CHECK_VERSION(2, 16, 0)
#if HAVE_GIO
/* GTK+/ GdkPixbuf internal helper function
Copyright (C) 2008 Matthias Clasen <mclasen@redhat.com>

View file

@ -12,8 +12,12 @@
#ifndef __COMPAT_H__
#define __COMPAT_H__
#if HAVE_CONFIG_H
#include <config.h>
#endif
#include <glib.h>
#if GLIB_CHECK_VERSION(2, 16, 0)
#if HAVE_GIO
#include <gio/gio.h>
#endif
#include <webkit/webkit.h>
@ -22,7 +26,7 @@ G_BEGIN_DECLS
#if !GTK_CHECK_VERSION(2, 14, 0)
#if GLIB_CHECK_VERSION(2,16, 0)
#if HAVE_GIO
GdkPixbuf*
gdk_pixbuf_new_from_stream (GInputStream* stream,

View file

@ -61,7 +61,7 @@ typedef struct
GdkCursorType cursor_type;
gboolean custom_cursor;
GtkImageType storage_type;
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
GIcon *gicon;
#endif
gchar *icon_name;
@ -274,7 +274,7 @@ gtk_icon_entry_class_init (GtkIconEntryClass *klass)
NULL,
GTK_PARAM_WRITABLE));
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
g_object_class_install_property (gobject_class,
PROP_GICON_PRIMARY,
g_param_spec_object ("gicon-primary",
@ -433,7 +433,7 @@ gtk_icon_entry_set_property (GObject *object,
g_value_get_string (value));
break;
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
case PROP_GICON_PRIMARY:
gtk_icon_entry_set_icon_from_gicon (entry,
GTK_ICON_ENTRY_PRIMARY,
@ -471,7 +471,7 @@ gtk_icon_entry_get_property (GObject *object,
GTK_ICON_ENTRY_SECONDARY));
break;
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
case PROP_GICON_PRIMARY:
g_value_set_object (value,
gtk_icon_entry_get_gicon (entry,
@ -1104,7 +1104,7 @@ icon_theme_changed (GtkIconEntry *entry)
gtk_icon_entry_set_icon_from_icon_name (entry, i, priv->icons[i].icon_name);
}
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
else if (priv->icons[i].storage_type == _GTK_IMAGE_GICON)
{
g_object_unref (priv->icons[i].pixbuf);
@ -1339,7 +1339,7 @@ gtk_icon_entry_set_icon_from_icon_name (GtkIconEntry *entry,
* appropriately.
*/
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
void
gtk_icon_entry_set_icon_from_gicon (const GtkIconEntry *entry,
GtkIconEntryPosition icon_pos,
@ -1493,7 +1493,7 @@ gtk_icon_entry_get_pixbuf (const GtkIconEntry *entry,
*/
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
GIcon *
gtk_icon_entry_get_gicon (const GtkIconEntry *entry,
GtkIconEntryPosition icon_pos)

View file

@ -21,9 +21,12 @@
#ifndef __GTK_ICON_ENTRY_H__
#define __GTK_ICON_ENTRY_H__
#if HAVE_CONFIG_H
#include <config.h>
#endif
#include <glib.h>
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
#include <gio/gio.h>
#endif
#include <gtk/gtk.h>
@ -83,14 +86,14 @@ void gtk_icon_entry_set_icon_from_icon_name (GtkIconEntry *entry,
GtkIconEntryPosition icon_pos,
const gchar *icon_name);
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
void gtk_icon_entry_set_icon_from_gicon (const GtkIconEntry *entry,
GtkIconEntryPosition icon_pos,
GIcon *icon);
#endif
GdkPixbuf* gtk_icon_entry_get_pixbuf (const GtkIconEntry *entry,
GtkIconEntryPosition icon_pos);
#if GLIB_CHECK_VERSION (2, 16, 0)
#if HAVE_GIO
GIcon* gtk_icon_entry_get_gicon (const GtkIconEntry *entry,
GtkIconEntryPosition icon_pos);
#endif