summaryrefslogtreecommitdiff
path: root/demo
diff options
context:
space:
mode:
authorHubert Figuière <hub@figuiere.net>2013-08-08 22:58:08 -0400
committerHubert Figuière <hub@figuiere.net>2013-08-08 23:00:13 -0400
commit8423ebd1ef0a0c0f63e51b4fb7e9098366a9ea43 (patch)
tree44e45f5895066707b25bde38baca8b61cee88c6e /demo
parent3dd0951e431c8d54a1d57679b2e7c662dad3e318 (diff)
Fix another glib 2.36 deprecation warning.
Diffstat (limited to 'demo')
-rw-r--r--demo/gdk.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/demo/gdk.c b/demo/gdk.c
index 93d8bf9..1f5d10a 100644
--- a/demo/gdk.c
+++ b/demo/gdk.c
@@ -1,7 +1,7 @@
/*
* libopenraw - gdk.c
*
- * Copyright (C) 2007 Hubert Figuiere
+ * Copyright (C) 2007-2013 Hubert Figuiere
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -29,15 +29,18 @@ int
main(int argc, char **argv)
{
char *filename = argv[1];
-
+
(void)argc;
or_debug_set_level(DEBUG2);
+#if !GLIB_CHECK_VERSION(2,36,0)
+ /* deprecated in 2.36 */
g_type_init();
-
+#endif
+
if(filename && *filename)
{
GdkPixbuf *pixbuf;
-
+
pixbuf = or_gdkpixbuf_extract_rotated_thumbnail(filename, 160);
if(pixbuf) {
gdk_pixbuf_save (pixbuf, "gdk.jpg", "jpeg", NULL,
@@ -51,7 +54,7 @@ main(int argc, char **argv)
else {
printf("No input file name\n");
}
-
+
return 0;
}
/*