Commit bda1f355 authored by Matthias Clasen's avatar Matthias Clasen

Inclusion cleanups in sources

Try to do inclusions in the same sequence, more or less.
parent 88ef199e
......@@ -26,10 +26,8 @@
#include "config.h"
#include <string.h>
#include <stdlib.h>
#include "gdkmain.h"
#include "gdk.h"
#include "gdkinternals.h"
#include "gdkintl.h"
......@@ -37,6 +35,9 @@
#include "gdkkeysyms.h"
#endif
#include <string.h>
#include <stdlib.h>
typedef struct _GdkPredicate GdkPredicate;
struct _GdkPredicate
......
......@@ -23,6 +23,7 @@
#include "config.h"
#include "gdkapplaunchcontext.h"
#include "gdkinternals.h"
#include "gdkscreen.h"
#include "gdkintl.h"
......
......@@ -17,13 +17,14 @@
* Boston, MA 02111-1307, USA.
*/
#include "gdkcairo.h"
#include "config.h"
#include <math.h>
#include "gdkcairo.h"
#include "gdkdrawable.h"
#include "gdkinternals.h"
#include <math.h>
/**
* SECTION:cairo_interaction
......
......@@ -25,12 +25,13 @@
*/
#include "config.h"
#include <time.h>
#include "gdkscreen.h"
#include "gdkcolor.h"
#include "gdkscreen.h"
#include "gdkinternals.h"
#include <time.h>
/**
* SECTION:colors
......
......@@ -25,7 +25,9 @@
*/
#include "config.h"
#include "gdkcursor.h"
#include "gdkdisplay.h"
#include "gdkinternals.h"
......
......@@ -18,7 +18,9 @@
*/
#include "config.h"
#include "gdkdevice.h"
#include "gdkdeviceprivate.h"
#include "gdkintl.h"
#include "gdkinternals.h"
......
......@@ -18,7 +18,9 @@
*/
#include "config.h"
#include "gdkdevicemanager.h"
#include "gdkintl.h"
#include "gdkinternals.h"
......
......@@ -22,15 +22,17 @@
*/
#include "config.h"
#include <math.h>
#include <glib.h>
#include "gdk.h" /* gdk_event_send_client_message() */
#include "gdkdisplay.h"
#include "gdkevents.h"
#include "gdkwindowimpl.h"
#include "gdkinternals.h"
#include "gdkmarshalers.h"
#include "gdkscreen.h"
#include <glib.h>
#include <math.h>
enum {
OPENED,
......
......@@ -26,13 +26,12 @@
#include "config.h"
#include "gdkscreen.h"
#include "gdkdisplay.h"
#include "gdkdisplaymanager.h"
#include "gdkscreen.h"
#include "gdkdisplay.h"
#include "gdkinternals.h"
#include "gdkmarshalers.h"
#include "gdkintl.h"
......
......@@ -25,9 +25,11 @@
*/
#include "config.h"
#include <gdkdnd.h>
#include <gdkdisplay.h>
#include <gdkwindow.h>
#include "gdkdnd.h"
#include "gdkdisplay.h"
#include "gdkwindow.h"
/**
......
......@@ -25,16 +25,18 @@
*/
#include "config.h"
#include <math.h>
#include <pango/pangocairo.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
#include "gdkcairo.h"
#include "gdkdrawable.h"
#include "gdkcairo.h"
#include "gdkinternals.h"
#include "gdkwindow.h"
#include "gdkscreen.h"
#include "gdkpixbuf.h"
#include <pango/pangocairo.h>
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <math.h>
G_DEFINE_ABSTRACT_TYPE (GdkDrawable, gdk_drawable, G_TYPE_OBJECT)
......
......@@ -25,12 +25,11 @@
*/
#include "config.h"
#include <string.h> /* For memset() */
#include <math.h>
#include "gdk.h"
#include "gdkinternals.h"
#include <string.h>
#include <math.h>
typedef struct _GdkIOClosure GdkIOClosure;
......
......@@ -26,11 +26,11 @@
#include "config.h"
#include <stdio.h>
#include "gdktypes.h"
#include "gdkprivate.h"
#include <stdio.h>
guint _gdk_debug_flags = 0;
GList *_gdk_default_filters = NULL;
......
......@@ -25,9 +25,6 @@
*/
#include "config.h"
#include <glib/gprintf.h>
#include <stdlib.h>
#include <string.h>
#include "gdkkeysyms.h"
#include "gdkinternals.h"
......@@ -36,6 +33,10 @@
#include "keyname-table.h"
#include <glib/gprintf.h>
#include <stdlib.h>
#include <string.h>
#define GDK_NUM_KEYS G_N_ELEMENTS (gdk_keys_by_keyval)
static int
......
......@@ -26,9 +26,10 @@
#include "config.h"
#include "gdkdisplay.h"
#include "gdkkeys.h"
#include "gdkdisplay.h"
enum {
DIRECTION_CHANGED,
......
......@@ -25,7 +25,8 @@
*/
#include "config.h"
#include "gdk.h"
#include "gdktypes.h"
/* Thanks to Markus G. Kuhn <mkuhn@acm.org> for the ksysym<->Unicode
......
......@@ -27,6 +27,8 @@
#include "config.h"
#include "gdkmedialib.h"
#include <stdlib.h>
#include <dlfcn.h>
......@@ -44,8 +46,6 @@
#include <sys/sysinfo.h>
#endif
#include "gdkmedialib.h"
typedef char * (*ml_version) (void);
static ml_version medialib_version = mlib_version;
......
......@@ -26,12 +26,11 @@
#include "config.h"
#include <math.h>
#include "gdkwindow.h"
#include "gdkinternals.h"
#include "gdkwindowimpl.h"
#include <math.h>
/* LIMITATIONS:
*
......
......@@ -18,12 +18,15 @@
*/
#include "config.h"
#include <math.h>
#include <pango/pangocairo.h>
#include "gdkpango.h"
#include "gdkscreen.h"
#include "gdkintl.h"
#include <math.h>
#include <pango/pangocairo.h>
/* Get a clip region to draw only part of a layout. index_ranges
* contains alternating range starts/stops. The region is the
* region which contains the given ranges, i.e. if you draw with the
......
......@@ -23,13 +23,14 @@
*/
#include "config.h"
#include <gdk-pixbuf/gdk-pixbuf.h>
#include "gdkpixbuf.h"
#include "gdkcolor.h"
#include "gdkwindow.h"
#include "gdkpixbuf.h"
#include "gdkinternals.h"
#include <gdk-pixbuf/gdk-pixbuf.h>
/**
* SECTION:pixbufs
......
......@@ -25,7 +25,8 @@
*/
#include "config.h"
#include <gdk/gdk.h>
#include "gdkrectangle.h"
/**
......
......@@ -22,9 +22,11 @@
*/
#include "config.h"
#include "gdk.h" /* For gdk_rectangle_intersect() */
#include "gdkwindow.h"
#include "gdkscreen.h"
#include "gdkrectangle.h"
#include "gdkwindow.h"
#include "gdkintl.h"
......
......@@ -25,9 +25,11 @@
*/
#include "config.h"
#include "gdkselection.h"
#include "gdkproperty.h"
#include "gdkdisplay.h"
#include "gdkselection.h"
gboolean
......
......@@ -22,7 +22,9 @@
*/
#include "config.h"
#include "gdkvisual.h"
#include "gdkscreen.h"
......
......@@ -34,9 +34,8 @@
#ifdef GDK_WINDOWING_X11
#include "x11/gdkx.h" /* For workaround */
#endif
#include "math.h"
#include "gdk.h" /* For gdk_rectangle_union() */
#include "gdkrectangle.h"
#include "gdkinternals.h"
#include "gdkintl.h"
#include "gdkscreen.h"
......@@ -46,6 +45,8 @@
#include "gdkscreen.h"
#include "gdkwindowimpl.h"
#include <math.h>
#undef DEBUG_WINDOW_PRINTING
......
......@@ -25,7 +25,9 @@
*/
#include "config.h"
#include "gdkwindowimpl.h"
#include "gdkinternals.h"
......
......@@ -17,8 +17,13 @@
* Boston, MA 02111-1307, USA.
*/
#include <string.h>
#include "config.h"
#include "gdktypes.h"
#include <glib.h>
#include <string.h>
#include "gdksettings.c"
int
......
......@@ -22,18 +22,18 @@
#include "config.h"
#include <string.h>
#include <unistd.h>
#include <glib.h>
#include <gio/gdesktopappinfo.h>
#include "gdkapplaunchcontext.h"
#include "gdkx.h"
#include "gdkapplaunchcontext.h"
#include "gdkscreen.h"
#include "gdkinternals.h"
#include "gdkintl.h"
#include <glib.h>
#include <gio/gdesktopappinfo.h>
#include <string.h>
#include <unistd.h>
static char *
get_display_name (GFile *file)
......
......@@ -44,12 +44,15 @@ in this Software without prior written authorization from The Open Group.
*/
#include "config.h"
#include "gdkasync.h"
#include "gdkx.h"
#ifdef NEED_XIPROTO_H_FOR_XREPLY
#include <X11/extensions/XIproto.h>
#endif
#include <X11/Xlibint.h>
#include "gdkasync.h"
#include "gdkx.h"
typedef struct _ChildInfoChildState ChildInfoChildState;
......
......@@ -26,7 +26,14 @@
#include "config.h"
#include "gdkcursor.h"
#include "gdkprivate-x11.h"
#include "gdkdisplay-x11.h"
#include "gdkx.h"
#define GDK_PIXBUF_ENABLE_BACKEND
#include <gdk-pixbuf/gdk-pixbuf.h>
#include <X11/Xlib.h>
#include <X11/cursorfont.h>
......@@ -38,11 +45,6 @@
#endif
#include <string.h>
#include "gdkprivate-x11.h"
#include "gdkcursor.h"
#include "gdkdisplay-x11.h"
#include "gdkx.h"
#include <gdk-pixbuf/gdk-pixbuf.h>
static guint theme_serial = 0;
......
......@@ -19,8 +19,9 @@
#include "config.h"
#include <gdk/gdkwindow.h>
#include "gdkdevice-core.h"
#include "gdkwindow.h"
#include "gdkprivate-x11.h"
#include "gdkx.h"
......
......@@ -19,9 +19,10 @@
#include "config.h"
#include <gdk/gdkwindow.h>
#include "gdkdeviceprivate.h"
#include "gdkdevice-xi.h"
#include "gdkwindow.h"
#include "gdkdeviceprivate.h"
#include "gdkprivate-x11.h"
#include "gdkintl.h"
#include "gdkx.h"
......
......@@ -19,11 +19,12 @@
#include "config.h"
#include <X11/extensions/XInput2.h>
#include "gdkdevice-xi2.h"
#include "gdkintl.h"
#include "gdkx.h"
#include <X11/extensions/XInput2.h>
struct _GdkDeviceXI2Private
{
......
......@@ -19,9 +19,10 @@
#include "config.h"
#include <gdk/gdktypes.h>
#include <gdk/gdkdevicemanager.h>
#include "gdkdevicemanager-core.h"
#include "gdktypes.h"
#include "gdkdevicemanager.h"
#include "gdkeventtranslator.h"
#include "gdkdevice-core.h"
#include "gdkkeysyms.h"
......
......@@ -18,15 +18,15 @@
*/
#include "config.h"
#include "gdkx.h"
#include "gdkdevicemanager-core.h"
#include "gdkdevicemanager-core.h"
#ifdef XINPUT_XFREE
#include "gdkdevicemanager-xi.h"
#ifdef XINPUT_2
#include "gdkdevicemanager-xi2.h"
#endif
#endif
#include "gdkx.h"
GdkDeviceManager *
_gdk_device_manager_new (GdkDisplay *display)
......
......@@ -20,6 +20,7 @@
#include "config.h"
#include "gdkdevicemanager-xi.h"
#include "gdkeventtranslator.h"
#include "gdkdevice-xi.h"
#include "gdkintl.h"
......
......@@ -19,16 +19,17 @@
#include "config.h"
#include <string.h>
#include <gdk/gdkdeviceprivate.h>
#include "gdkdevicemanager-xi2.h"
#include <gdk/gdkdeviceprivate.h>
#include "gdkeventtranslator.h"
#include "gdkdevice-xi2.h"
#include "gdkkeysyms.h"
#include "gdkprivate-x11.h"
#include "gdkx.h"
#include <string.h>
#define HAS_FOCUS(toplevel) ((toplevel)->has_focus || (toplevel)->has_pointer_focus)
......
......@@ -24,17 +24,11 @@
#include "config.h"
#include <glib/gprintf.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>
#include "gdkdisplay-x11.h"
#include <glib.h>
#include "gdkx.h"
#include "gdkasync.h"
#include "gdkdisplay.h"
#include "gdkdisplay-x11.h"
#include "gdkeventsource.h"
#include "gdkeventtranslator.h"
#include "gdkscreen.h"
......@@ -44,6 +38,13 @@
#include "gdkdevicemanager.h"
#include "xsettings-client.h"
#include <glib.h>
#include <glib/gprintf.h>
#include <stdlib.h>
#include <string.h>
#include <errno.h>
#include <unistd.h>
#include <X11/Xatom.h>
#ifdef HAVE_XKB
......
......@@ -26,24 +26,25 @@
#include "config.h"
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/Xatom.h>
#include <X11/extensions/shape.h>
#include <X11/extensions/Xcomposite.h>
#include <string.h>
#include "gdkdnd.h"
#include "gdk.h" /* For gdk_flush() */
#include "gdkmain.h"
#include "gdkx.h"
#include "gdkasync.h"
#include "gdkdnd.h"
#include "gdkproperty.h"
#include "gdkprivate-x11.h"
#include "gdkinternals.h"
#include "gdkscreen-x11.h"
#include "gdkdisplay-x11.h"
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/Xatom.h>
#include <X11/extensions/shape.h>
#include <X11/extensions/Xcomposite.h>
#include <string.h>
typedef struct _GdkDragContextPrivateX11 GdkDragContextPrivateX11;
typedef enum {
......
......@@ -26,17 +26,17 @@
#include "config.h"
#include "gdkdrawable-x11.h"
#include "gdkx.h"
#include "gdkprivate-x11.h"
#include "gdkscreen-x11.h"
#include "gdkdisplay-x11.h"
#include <cairo-xlib.h>
#include <stdlib.h>
#include <string.h> /* for memcpy() */
#include "gdkprivate-x11.h"
#include "gdkdrawable-x11.h"
#include "gdkscreen-x11.h"
#include "gdkdisplay-x11.h"
#include <string.h>
static cairo_surface_t *gdk_x11_ref_cairo_surface (GdkDrawable *drawable);
......
......@@ -20,6 +20,7 @@
#include "config.h"
#include "gdkeventsource.h"
#include "gdkinternals.h"
#include "gdkx.h"
......
......@@ -18,7 +18,8 @@
*/
#include "config.h"
#include "gdk.h" /* For gdk_rectangle_intersect */
#include "gdkrectangle.h"
#include "gdkprivate-x11.h"
#include "gdkx.h"
#include "gdkinternals.h"
......
......@@ -25,11 +25,12 @@
*/
#include "config.h"
#include <stdio.h>
#include "gdktypes.h"
#include "gdkprivate-x11.h"
#include <stdio.h>
gboolean _gdk_use_xshm = TRUE; /* used as a cmd line arg */
GdkAtom _gdk_selection_property;
......
......@@ -26,15 +26,15 @@
#include "config.h"
#include <locale.h>
#include <stdlib.h>
#include <string.h>
#include "gdkx.h"
#include "gdk.h" /* For gdk_flush() */
#include "gdkmain.h"
#include "gdkinternals.h"
#include "gdkdisplay-x11.h"
#include <locale.h>
#include <stdlib.h>
#include <string.h>
/* If this variable is FALSE, it indicates that we should
* avoid trying to use multibyte conversion functions and
......
......@@ -26,12 +26,12 @@
#include "config.h"
#include <stdlib.h>
#include "gdkscreen-x11.h"
#include "gdkdisplay-x11.h"
#include "gdkwindow.h"
#include <stdlib.h>
/* Addition used for extension_events mask */
#define GDK_ALL_DEVICES_MASK (1<<30)
......
......@@ -26,6 +26,12 @@
#include "config.h"
#include "gdkx.h"
#include "gdkprivate-x11.h"
#include "gdkinternals.h"
#include "gdkdisplay-x11.h"
#include "gdkkeysyms.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
......@@ -33,14 +39,6 @@
#include <limits.h>
#include <errno.h>
#include "gdk.h"
#include "gdkx.h"
#include "gdkprivate-x11.h"
#include "gdkinternals.h"
#include "gdkdisplay-x11.h"