gtk+ r20214 - trunk/gdk-pixbuf



Author: mitch
Date: Wed May 28 13:39:52 2008
New Revision: 20214
URL: http://svn.gnome.org/viewvc/gtk+?rev=20214&view=rev

Log:
2008-05-28  Michael Natterer  <mitch imendio com>

	* gdk-pixbuf.h: define GDK_PIXBUF_H_INSIDE around including all
	other headers.

	* gdk-pixbuf-animation.h
	* gdk-pixbuf-core.h
	* gdk-pixbuf-enum-types.h.template
	* gdk-pixbuf-features.h.in
	* gdk-pixbuf-io.h
	* gdk-pixbuf-loader.h
	* gdk-pixbuf-simple-anim.h
	* gdk-pixbuf-transform.h: add single-include guards that #error
	out if GDK_PIXBUF_DISABLE_SINGLE_INCLUDES is defined and any of
	these files is included individually.

	* gdk-pixbuf-private.h: don't incude "gdk-pixbuf-io.h".

	* gdk-pixbuf-csource.c: #define __GTK_H_INSIDE__ around including
	"../gtk/gtkversion.h". Ugly but needed in this special case.



Modified:
   trunk/gdk-pixbuf/ChangeLog
   trunk/gdk-pixbuf/gdk-pixbuf-animation.h
   trunk/gdk-pixbuf/gdk-pixbuf-core.h
   trunk/gdk-pixbuf/gdk-pixbuf-csource.c
   trunk/gdk-pixbuf/gdk-pixbuf-enum-types.h.template
   trunk/gdk-pixbuf/gdk-pixbuf-features.h.in
   trunk/gdk-pixbuf/gdk-pixbuf-io.h
   trunk/gdk-pixbuf/gdk-pixbuf-loader.h
   trunk/gdk-pixbuf/gdk-pixbuf-private.h
   trunk/gdk-pixbuf/gdk-pixbuf-simple-anim.h
   trunk/gdk-pixbuf/gdk-pixbuf-transform.h
   trunk/gdk-pixbuf/gdk-pixbuf.h

Modified: trunk/gdk-pixbuf/gdk-pixbuf-animation.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-animation.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-animation.h	Wed May 28 13:39:52 2008
@@ -24,10 +24,13 @@
  * Boston, MA 02111-1307, USA.
  */
 
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_ANIMATION_H
 #define GDK_PIXBUF_ANIMATION_H
 
-#include <glib.h>
 #include <glib-object.h>
 #include <gdk-pixbuf/gdk-pixbuf-core.h>
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-core.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-core.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-core.h	Wed May 28 13:39:52 2008
@@ -23,6 +23,10 @@
  * Boston, MA 02111-1307, USA.
  */
 
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_CORE_H
 #define GDK_PIXBUF_CORE_H
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-csource.c
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-csource.c	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-csource.c	Wed May 28 13:39:52 2008
@@ -18,7 +18,9 @@
  */
 #include <config.h>
 
+#define __GTK_H_INSIDE__
 #include "../gtk/gtkversion.h"	/* versioning */
+#undef __GTK_H_INSIDE__
 #include "gdk-pixbuf.h"
 #include "gdk-pixdata.h"
 #include <glib/gprintf.h>

Modified: trunk/gdk-pixbuf/gdk-pixbuf-enum-types.h.template
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-enum-types.h.template	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-enum-types.h.template	Wed May 28 13:39:52 2008
@@ -1,4 +1,8 @@
 /*** BEGIN file-header ***/
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef __GDK_PIXBUF_ENUM_TYPES_H__
 #define __GDK_PIXBUF_ENUM_TYPES_H__
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-features.h.in
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-features.h.in	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-features.h.in	Wed May 28 13:39:52 2008
@@ -1,3 +1,7 @@
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_FEATURES_H
 #define GDK_PIXBUF_FEATURES_H 1
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-io.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-io.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-io.h	Wed May 28 13:39:52 2008
@@ -26,6 +26,10 @@
  * Boston, MA 02111-1307, USA.
  */
 
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_IO_H
 #define GDK_PIXBUF_IO_H
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-loader.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-loader.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-loader.h	Wed May 28 13:39:52 2008
@@ -23,6 +23,10 @@
  * Boston, MA 02111-1307, USA.
  */
 
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_LOADER_H
 #define GDK_PIXBUF_LOADER_H
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-private.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-private.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-private.h	Wed May 28 13:39:52 2008
@@ -28,7 +28,6 @@
 #define GDK_PIXBUF_PRIVATE_H
 
 #include "gdk-pixbuf.h"
-#include "gdk-pixbuf-io.h"
 #include "gdk-pixbuf-i18n.h"
 #include <stdio.h>
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-simple-anim.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-simple-anim.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-simple-anim.h	Wed May 28 13:39:52 2008
@@ -21,6 +21,10 @@
  * Boston, MA 02111-1307, USA.
  */
 
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_SIMPLE_ANIM_H
 #define GDK_PIXBUF_SIMPLE_ANIM_H
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf-transform.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf-transform.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf-transform.h	Wed May 28 13:39:52 2008
@@ -23,6 +23,10 @@
  * Boston, MA 02111-1307, USA.
  */
 
+#if defined(GDK_PIXBUF_DISABLE_SINGLE_INCLUDES) && !defined (GDK_PIXBUF_H_INSIDE) && !defined (GDK_PIXBUF_COMPILATION)
+#error "Only <gdk-pixbuf/gdk-pixbuf.h> can be included directly."
+#endif
+
 #ifndef GDK_PIXBUF_TRANSFORM_H
 #define GDK_PIXBUF_TRANSFORM_H
 

Modified: trunk/gdk-pixbuf/gdk-pixbuf.h
==============================================================================
--- trunk/gdk-pixbuf/gdk-pixbuf.h	(original)
+++ trunk/gdk-pixbuf/gdk-pixbuf.h	Wed May 28 13:39:52 2008
@@ -26,6 +26,8 @@
 #ifndef GDK_PIXBUF_H
 #define GDK_PIXBUF_H
 
+#define GDK_PIXBUF_H_INSIDE
+
 #include <glib.h>
 #include <gdk-pixbuf/gdk-pixbuf-features.h>
 #include <glib-object.h>
@@ -38,5 +40,6 @@
 #include <gdk-pixbuf/gdk-pixbuf-loader.h>
 #include <gdk-pixbuf/gdk-pixbuf-enum-types.h>
 
+#undef GDK_PIXBUF_H_INSIDE
 
 #endif  /* GDK_PIXBUF_H */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]