Commit 98440ad0 authored by Matthias Clasen's avatar Matthias Clasen

Remove gtktypeutils altogether

Based on patches by Javier Jardón.

https://bugzilla.gnome.org/show_bug.cgi?id=629955
parent 1283368b
......@@ -333,7 +333,6 @@ gtk_public_h_sources = \
gtktreestore.h \
gtktreeview.h \
gtktreeviewcolumn.h \
gtktypeutils.h \
gtkuimanager.h \
gtkvbbox.h \
gtkvbox.h \
......@@ -662,7 +661,6 @@ gtk_base_c_sources = \
gtktreeview.c \
gtktreeviewcolumn.c \
gtktypebuiltins.c \
gtktypeutils.c \
gtkuimanager.c \
gtkvbbox.c \
gtkvbox.c \
......
......@@ -217,7 +217,7 @@
#include <gtk/gtktreestore.h>
#include <gtk/gtktreeview.h>
#include <gtk/gtktreeviewcolumn.h>
#include <gtk/gtktypeutils.h>
#include <gtk/gtktypebuiltins.h>
#include <gtk/gtkuimanager.h>
#include <gtk/gtkvbbox.h>
#include <gtk/gtkvbox.h>
......
......@@ -54,6 +54,7 @@
#include "gtkmain.h"
#include "gtkmessagedialog.h"
#include "gtktogglebutton.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkintl.h"
......
......@@ -36,7 +36,7 @@
#define __GTK_ACTION_GROUP_H__
#include <gtk/gtkaction.h>
#include <gtk/gtktypeutils.h> /* for GtkTranslateFunc */
#include <gtk/gtkstock.h>
G_BEGIN_DECLS
......
......@@ -71,7 +71,7 @@
#include "gtksizegroup.h"
#include "gtksizerequest.h"
#include "gtkstock.h"
#include "gtktypebuiltins.h"
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtkbuildable.h"
......
......@@ -32,16 +32,19 @@
#include <stdarg.h>
#include "gtkbindings.h"
#include "gtktypeutils.h"
#include "gtkkeyhash.h"
#include "gtkwidget.h"
#include "gtkrc.h"
#include "gtkintl.h"
/* --- defines --- */
#define BINDING_MOD_MASK() (gtk_accelerator_get_default_mod_mask () | GDK_RELEASE_MASK)
#define GTK_TYPE_IDENTIFIER (gtk_identifier_get_type ())
GType gtk_identifier_get_type (void) G_GNUC_CONST;
/* --- structures --- */
typedef struct {
GtkPathType type;
......@@ -60,6 +63,20 @@ static GQuark key_id_class_binding_set = 0;
/* --- functions --- */
GType
gtk_identifier_get_type (void)
{
static GType our_type = 0;
if (our_type == 0)
{
GTypeInfo tinfo = { 0, };
our_type = g_type_register_static (G_TYPE_STRING, I_("GtkIdentifier"), &tinfo, 0);
}
return our_type;
}
static void
pattern_spec_free (PatternSpec *pspec)
{
......
......@@ -55,6 +55,7 @@
#include "gtkiconfactory.h"
#include "gtkactivatable.h"
#include "gtksizerequest.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkintl.h"
......
......@@ -28,6 +28,7 @@
#include "gtkeventbox.h"
#include "gtkmain.h"
#include "gtksizerequest.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
......
......@@ -40,6 +40,7 @@
#include "gtktreeselection.h"
#include "gtkvseparator.h"
#include "gtkwindow.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include <gobject/gvaluecollector.h>
......
......@@ -32,8 +32,12 @@
#include <string.h>
#include <stdlib.h>
#include <gobject/gobjectnotifyqueue.c>
#include <gobject/gvaluecollector.h>
#include "gtkbuildable.h"
#include "gtkbuilderprivate.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkmain.h"
#include "gtkmarshalers.h"
......@@ -42,8 +46,6 @@
#include "gtkwindow.h"
#include "gtkintl.h"
#include "gtktoolbar.h"
#include <gobject/gobjectnotifyqueue.c>
#include <gobject/gvaluecollector.h>
/**
......
......@@ -58,6 +58,7 @@
#include "gtkwindow.h"
#include "gtktreeview.h"
#include "gtktreeselection.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkentryprivate.h"
#include "gtkcelllayout.h"
......
......@@ -52,6 +52,7 @@
#include "gtkfilechooserbutton.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
/* **************** *
......
......@@ -29,6 +29,7 @@
#include "gtkframe.h"
#include "gtklabel.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
#include "gtkintl.h"
#include "gtkbuildable.h"
......
......@@ -26,12 +26,15 @@
*/
#include "config.h"
#include <stdlib.h>
#include "gtkhandlebox.h"
#include "gtkinvisible.h"
#include "gtkmain.h"
#include "gtkmarshalers.h"
#include "gtkwindow.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkintl.h"
......
......@@ -25,9 +25,11 @@
*/
#include "config.h"
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include "gtkiconfactory.h"
#include "gtkiconcache.h"
#include "gtkdebug.h"
......@@ -38,7 +40,7 @@
#include "gtkintl.h"
#include "gtkbuildable.h"
#include "gtkbuilderprivate.h"
#include "gtktypebuiltins.h"
static GSList *all_icon_factories = NULL;
......
......@@ -41,6 +41,7 @@
#include "gtkscrollable.h"
#include "gtksizerequest.h"
#include "gtktreednd.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
/**
......
......@@ -25,6 +25,7 @@
*/
#include "config.h"
#include <math.h>
#include <string.h>
......@@ -36,6 +37,7 @@
#include "gtksizerequest.h"
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
/**
* SECTION:gtkimage
......
......@@ -46,6 +46,7 @@
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtkstock.h"
#include "gtktypebuiltins.h"
/**
* SECTION:gtkinfobar
......
......@@ -50,6 +50,7 @@
#include "gtkshow.h"
#include "gtktooltip.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
/*rint() is only available in GCC and/or C99*/
#if (__STDC_VERSION__ < 199901L && !defined __GNUC__)
......
......@@ -33,7 +33,6 @@
#include <gdk/gdk.h>
#include <gtk/gtktypeutils.h>
#include <gtk/gtkwidget.h>
#ifdef G_PLATFORM_WIN32
#include <gtk/gtkbox.h>
......
......@@ -46,6 +46,7 @@
#include "gtksettings.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
#define NAVIGATION_REGION_OVERSHOOT 50 /* How much the navigation region
* extends below the submenu
......
......@@ -37,9 +37,9 @@
#include "gtksettings.h"
#include "gtksizerequest.h"
#include "gtkwindow.h"
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
#define BORDER_SPACING 0
#define DEFAULT_IPADDING 1
......
......@@ -25,6 +25,7 @@
*/
#include "config.h"
#include <string.h>
#include "gtkaccellabel.h"
......@@ -40,6 +41,7 @@
#include "gtkbuildable.h"
#include "gtkactivatable.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
enum {
......
......@@ -40,6 +40,7 @@
#include "gtkwindow.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
#define MENU_SHELL_TIMEOUT 500
......
......@@ -26,6 +26,7 @@
*/
#include "config.h"
#include <string.h>
#include "gtkmessagedialog.h"
......@@ -39,6 +40,7 @@
#include "gtkiconfactory.h"
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
/**
* SECTION:gtkmessagedialog
......
......@@ -42,6 +42,7 @@
#include "gtkprivate.h"
#include "gtkdnd.h"
#include "gtkbuildable.h"
#include "gtktypebuiltins.h"
/**
......
......@@ -33,7 +33,7 @@
#include "gtkmarshalers.h"
#include "gtkorientable.h"
#include "gtkwindow.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkintl.h"
......
......@@ -23,14 +23,16 @@
#include <errno.h>
#include <stdlib.h>
#include <math.h>
#include <string.h>
#include <cairo-pdf.h>
#include "gtkprintoperation-private.h"
#include "gtkmarshalers.h"
#include <cairo-pdf.h>
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtkmessagedialog.h"
#include "gtktypebuiltins.h"
#define SHOW_PROGRESS_TIME 1200
......
......@@ -19,12 +19,16 @@
*/
#include "config.h"
#include <string.h>
#include <stdlib.h>
#include <glib/gprintf.h>
#include <gtk/gtk.h>
#include "gtkprintsettings.h"
#include "gtkprintutils.h"
#include "gtktypebuiltins.h"
#include "gtkwidget.h"
typedef struct _GtkPrintSettingsClass GtkPrintSettingsClass;
......
......@@ -20,14 +20,20 @@
*/
#include "config.h"
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <stdio.h>
#include <math.h>
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtkprintunixdialog.h"
#include "gtkcustompaperunixdialog.h"
#include "gtkprintbackend.h"
#include "gtkprinter-private.h"
#include "gtkprinteroptionwidget.h"
#include "gtkprintutils.h"
#include "gtkspinbutton.h"
#include "gtkcellrendererpixbuf.h"
......@@ -49,16 +55,11 @@
#include "gtklabel.h"
#include "gtkeventbox.h"
#include "gtkbuildable.h"
#include "gtkcustompaperunixdialog.h"
#include "gtkprintbackend.h"
#include "gtkprinter-private.h"
#include "gtkprintunixdialog.h"
#include "gtkprinteroptionwidget.h"
#include "gtkprintutils.h"
#include "gtkmessagedialog.h"
#include "gtkbutton.h"
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
#define EXAMPLE_PAGE_AREA_SIZE 110
#define RULER_DISTANCE 7.5
......
......@@ -39,6 +39,7 @@
#include "gtkwindow.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
/**
* SECTION:gtkrange
......
......@@ -53,7 +53,7 @@
#include "gtkstock.h"
#include "gtkvbox.h"
#include "gtkwindow.h"
#include "gtktypebuiltins.h"
#include "gtkintl.h"
/**
......
......@@ -34,6 +34,7 @@
#include "gtkscrolledwindow.h"
#include "gtkwindow.h"
#include "gtkprivate.h"
#include "gtktypebuiltins.h"
#include "gtkintl.h"
......
......@@ -43,6 +43,7 @@
#include "gtksettings.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
#define MIN_SPIN_BUTTON_WIDTH 30
#define MAX_TIMER_CALLS 5
......
......@@ -26,6 +26,7 @@
*/
#include "config.h"
#include "gtkframe.h"
#include "gtklabel.h"
#include "gtkmarshalers.h"
......@@ -34,6 +35,7 @@
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtkbuildable.h"
#include "gtktypebuiltins.h"
/**
* SECTION:gtkstatusbar
......
......@@ -42,27 +42,19 @@
#include "gtkprivate.h"
#include "gtkwidget.h"
#include "gtktooltip.h"
#include "gtkicontheme.h"
#include "gtklabel.h"
#include "gtktypebuiltins.h"
#ifdef GDK_WINDOWING_X11
#include "gdk/x11/gdkx.h"
#endif
#ifdef GDK_WINDOWING_WIN32
#include "gdk/win32/gdkwin32.h"
#endif
#ifdef GDK_WINDOWING_WIN32
#include "gtkicontheme.h"
#include "gtklabel.h"
#include "win32/gdkwin32.h"
#include "gdk/win32/gdkwin32.h"
#define WM_GTK_TRAY_NOTIFICATION (WM_USER+1)
#endif
#ifdef GDK_WINDOWING_QUARTZ
#include "gtkicontheme.h"
#include "gtklabel.h"
#endif
#define BLINK_TIMEOUT 500
enum
......
......@@ -33,10 +33,23 @@
#include <gdk/gdk.h>
#include <gtk/gtktypeutils.h> /* for GtkTranslateFunc */
G_BEGIN_DECLS
/*
* GtkTranslateFunc:
* @path: The id of the message. In #GtkActionGroup this will be a label
* or tooltip from a #GtkActionEntry.
* @func_data: user data passed in when registering the function
*
* The function used to translate messages in e.g. #GtkIconFactory
* and #GtkActionGroup.
*
* Returns: the translated message
*/
typedef gchar * (*GtkTranslateFunc) (const gchar *path,
gpointer func_data);
typedef struct _GtkStockItem GtkStockItem;
struct _GtkStockItem
......
......@@ -48,6 +48,10 @@
*/
#include "config.h"
#include <stdlib.h>
#include <string.h>
#include "gtkmain.h"
#include "gtktexttag.h"
#include "gtktexttypes.h"
......@@ -55,9 +59,7 @@
#include "gtkintl.h"
#include "gtkmarshalers.h"
#include "gtkprivate.h"
#include <stdlib.h>
#include <string.h>
#include "gtktypebuiltins.h"
enum {
EVENT,
......
......@@ -50,6 +50,7 @@
#include "gtkwidgetprivate.h"
#include "gtkwindow.h"
#include "gtkscrollable.h"
#include "gtktypebuiltins.h"
/**
......
......@@ -55,6 +55,7 @@
#include "gtkvbox.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
/**
......
......@@ -22,11 +22,11 @@
#include "config.h"
#include "gtktoolpaletteprivate.h"
#include <gtk/gtk.h>
#include <math.h>
#include <string.h>
#include "gtktoolpaletteprivate.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkintl.h"
......
......@@ -26,7 +26,7 @@
#include "gtktoolpaletteprivate.h"
#include "gtkmarshalers.h"
#include "gtktypebuiltins.h"
#include "gtkprivate.h"
#include "gtkscrollable.h"
#include "gtkintl.h"
......
......@@ -23,18 +23,20 @@
*/
#include "config.h"
#include <math.h>
#include <string.h>
#include "x11/gdkx.h"
#include <X11/Xatom.h>
#include <cairo-xlib.h>
#include "gtkintl.h"
#include "gtkprivate.h"
#include "gtktrayicon.h"
#include "gtktestutils.h"
#include "gtkdebug.h"
#include "x11/gdkx.h"
#include <X11/Xatom.h>
#include <cairo-xlib.h>
#include "gtktypebuiltins.h"
#define SYSTEM_TRAY_REQUEST_DOCK 0
#define SYSTEM_TRAY_BEGIN_MESSAGE 1
......
......@@ -49,6 +49,7 @@
#include "gtkprivate.h"
#include "gtkwidgetprivate.h"
#include "gtkentryprivate.h"
#include "gtktypebuiltins.h"
/**
......
......@@ -36,6 +36,7 @@
#include "gtkcellareabox.h"
#include "gtkprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
/**
......
/* GTK - The GIMP Toolkit
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
/*
* Modified by the GTK+ Team and others 1997-2000. See the AUTHORS
* file for a list of people on the GTK+ Team. See the ChangeLog
* files for a list of changes. These files are distributed with
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
#include "config.h"
#include <string.h> /* strcmp */
#include "gtktypeutils.h"
#include "gtkintl.h"
GType
gtk_identifier_get_type (void)
{
static GType our_type = 0;
if (our_type == 0)
{
GTypeInfo tinfo = { 0, };
our_type = g_type_register_static (G_TYPE_STRING, I_("GtkIdentifier"), &tinfo, 0);
}
return our_type;
}
/* GTK - The GIMP Toolkit
* Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
/*
* Modified by the GTK+ Team and others 1997-2000. See the AUTHORS
* file for a list of people on the GTK+ Team. See the ChangeLog
* files for a list of changes. These files are distributed with
* GTK+ at ftp://ftp.gtk.org/pub/gtk/.
*/
#if !defined (__GTK_H_INSIDE__) && !defined (GTK_COMPILATION)
#error "Only <gtk/gtk.h> can be included directly."
#endif
#ifndef __GTK_TYPE_UTILS_H__
#define __GTK_TYPE_UTILS_H__
/* enum types generated by glib-mkenums
*/
#include <gtk/gtktypebuiltins.h>
G_BEGIN_DECLS
/* urg */
#define GTK_TYPE_IDENTIFIER (gtk_identifier_get_type ())
GType gtk_identifier_get_type (void) G_GNUC_CONST;
typedef gchar * (*GtkTranslateFunc) (const gchar *path,
gpointer func_data);
G_END_DECLS
#endif /* __GTK_TYPE_UTILS_H__ */
......@@ -63,6 +63,7 @@
#include "gtkmodifierstyle.h"
#include "gtkversion.h"
#include "gtkdebug.h"
#include "gtktypebuiltins.h"
/**
......
......@@ -26,7 +26,7 @@
#include "config.h"
#include "gtkintl.h"
#include "gtkwindow.h"
#include <string.h>
#include <stdlib.h>
......@@ -35,7 +35,6 @@
#include "gtkprivate.h"
#include "gtkrc.h"
#include "gtkwindow.h"
#include "gtkwindowprivate.h"
#include "gtkaccelgroupprivate.h"
#include "gtkbindings.h"
......@@ -49,6 +48,8 @@
#include "gtkplug.h"
#include "gtkbuildable.h"
#include "gtkwidgetprivate.h"
#include "gtkintl.h"
#include "gtktypebuiltins.h"
#ifdef GDK_WINDOWING_X11
#include "x11/gdkx.h"
......
......@@ -197,7 +197,6 @@ gtk/gtktreesortable.c
gtk/gtktreestore.c
gtk/gtktreeview.c
gtk/gtktreeviewcolumn.c
gtk/gtktypeutils.c