From cdb84c7c776f214f41ba1a509efb2494e7ed1baf Mon Sep 17 00:00:00 2001
From: "P. F. Chimento" <philip.chimento@gmail.com>
Date: Sun, 3 Jun 2012 23:46:14 +0200
Subject: [PATCH] Replace deprecated functions

gdk_pixbuf_(un)ref -> g_object_(un)ref
---
 libchimara/graphics.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libchimara/graphics.c b/libchimara/graphics.c
index 0c3215a..1ab5a35 100644
--- a/libchimara/graphics.c
+++ b/libchimara/graphics.c
@@ -63,7 +63,7 @@ load_image_from_blorb(giblorb_result_t resource, glui32 image, gint width, gint
 	g_mutex_unlock(glk_data->resource_lock);
 
 	info->pixbuf = gdk_pixbuf_loader_get_pixbuf(loader);
-	gdk_pixbuf_ref(info->pixbuf);
+	g_object_ref(info->pixbuf);
 
 	g_object_unref(loader);
 	return info;
@@ -89,7 +89,7 @@ load_image_from_file(const gchar *filename, glui32 image, gint width, gint heigh
 		g_free(info);
 		return NULL;
 	}
-	gdk_pixbuf_ref(info->pixbuf);
+	g_object_ref(info->pixbuf);
 
 	return info;
 }
@@ -131,7 +131,7 @@ load_image_in_cache(glui32 image, gint width, gint height)
 
 	if( g_slist_length(glk_data->image_cache) >= IMAGE_CACHE_MAX_NUM ) {
 		struct image_info *head = (struct image_info*) glk_data->image_cache->data;
-		gdk_pixbuf_unref(head->pixbuf);
+		g_object_unref(head->pixbuf);
 		g_free(head);
 		glk_data->image_cache = g_slist_remove_link(glk_data->image_cache, glk_data->image_cache);
 	}
@@ -175,7 +175,7 @@ on_pixbuf_closed(GdkPixbufLoader *loader, gpointer data)
 void
 clear_image_cache(struct image_info *data, gpointer user_data)
 {
-	gdk_pixbuf_unref(data->pixbuf);
+	g_object_unref(data->pixbuf);
 	g_free(data);
 }
 
-- 
2.30.2