Commit 5c4f2ef0 authored by Michael Natterer's avatar Michael Natterer 😴

gtk: move _gtk_modules_has_mixed_deps() to gtkmodlesprivate.h

and remove gtkmainprivate.h completely.
parent 2688ccdb
...@@ -416,7 +416,6 @@ gtk_private_h_sources = \ ...@@ -416,7 +416,6 @@ gtk_private_h_sources = \
gtkimcontextsimpleseqs.h \ gtkimcontextsimpleseqs.h \
gtkintl.h \ gtkintl.h \
gtkkeyhash.h \ gtkkeyhash.h \
gtkmainprivate.h \
gtkmenuprivate.h \ gtkmenuprivate.h \
gtkmenuitemprivate.h \ gtkmenuitemprivate.h \
gtkmenushellprivate.h \ gtkmenushellprivate.h \
......
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
#include "gtktextview.h" #include "gtktextview.h"
#include "gtkiconfactory.h" #include "gtkiconfactory.h"
#include "gtkshow.h" #include "gtkshow.h"
#include "gtkmainprivate.h" #include "gtkmain.h"
#include "gtkmessagedialog.h" #include "gtkmessagedialog.h"
#include "gtktogglebutton.h" #include "gtktogglebutton.h"
#include "gtktypebuiltins.h" #include "gtktypebuiltins.h"
......
...@@ -33,7 +33,6 @@ ...@@ -33,7 +33,6 @@
#include "gtkaccellabel.h" #include "gtkaccellabel.h"
#include "gtkaccelmap.h" #include "gtkaccelmap.h"
#include "gtkintl.h" #include "gtkintl.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkprivate.h" #include "gtkprivate.h"
......
...@@ -41,7 +41,6 @@ ...@@ -41,7 +41,6 @@
#include "gtkseparator.h" #include "gtkseparator.h"
#include "gtkwindow.h" #include "gtkwindow.h"
#include "gtktypebuiltins.h" #include "gtktypebuiltins.h"
#include "gtkmainprivate.h"
#include "gtkprivate.h" #include "gtkprivate.h"
#include <gobject/gvaluecollector.h> #include <gobject/gvaluecollector.h>
......
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
#include "gtkbox.h" #include "gtkbox.h"
#include "gtkwindow.h" #include "gtkwindow.h"
#include "gtkentry.h" #include "gtkentry.h"
#include "gtkmainprivate.h" #include "gtkmain.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkprivate.h" #include "gtkprivate.h"
......
...@@ -35,7 +35,6 @@ ...@@ -35,7 +35,6 @@
#include "gtkimmodule.h" #include "gtkimmodule.h"
#include "gtkimcontextsimple.h" #include "gtkimcontextsimple.h"
#include "gtksettings.h" #include "gtksettings.h"
#include "gtkmainprivate.h"
#include "gtkprivate.h" #include "gtkprivate.h"
#include "gtkintl.h" #include "gtkintl.h"
......
...@@ -31,7 +31,6 @@ ...@@ -31,7 +31,6 @@
#include "gtklabel.h" #include "gtklabel.h"
#include "gtkaccellabel.h" #include "gtkaccellabel.h"
#include "gtkdnd.h" #include "gtkdnd.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkpango.h" #include "gtkpango.h"
#include "gtkwindow.h" #include "gtkwindow.h"
......
...@@ -55,7 +55,7 @@ ...@@ -55,7 +55,7 @@
#include "gtkdnd.h" #include "gtkdnd.h"
#include "gtkimagemenuitem.h" #include "gtkimagemenuitem.h"
#include "gtklabel.h" #include "gtklabel.h"
#include "gtkmainprivate.h" #include "gtkmain.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkmenu.h" #include "gtkmenu.h"
#include "gtkmenuitem.h" #include "gtkmenuitem.h"
......
...@@ -91,9 +91,6 @@ ...@@ -91,9 +91,6 @@
#include "config.h" #include "config.h"
#include "gtkmainprivate.h"
#include <glib.h>
#include "gdk/gdk.h" #include "gdk/gdk.h"
#include <locale.h> #include <locale.h>
...@@ -117,19 +114,20 @@ ...@@ -117,19 +114,20 @@
#include "gtkaccelmap.h" #include "gtkaccelmap.h"
#include "gtkbox.h" #include "gtkbox.h"
#include "gtkclipboard.h" #include "gtkclipboard.h"
#include "gtkdebug.h"
#include "gtkdnd.h" #include "gtkdnd.h"
#include "gtkversion.h" #include "gtkmain.h"
#include "gtkmenu.h"
#include "gtkmodules.h" #include "gtkmodules.h"
#include "gtkmodulesprivate.h" #include "gtkmodulesprivate.h"
#include "gtkprivate.h"
#include "gtkrecentmanager.h" #include "gtkrecentmanager.h"
#include "gtkselectionprivate.h" #include "gtkselectionprivate.h"
#include "gtksettingsprivate.h" #include "gtksettingsprivate.h"
#include "gtktooltip.h"
#include "gtkversion.h"
#include "gtkwidgetprivate.h" #include "gtkwidgetprivate.h"
#include "gtkwindowprivate.h" #include "gtkwindowprivate.h"
#include "gtktooltip.h"
#include "gtkdebug.h"
#include "gtkmenu.h"
#include "gtkprivate.h"
/* Private type definitions /* Private type definitions
...@@ -622,32 +620,6 @@ setlocale_initialization (void) ...@@ -622,32 +620,6 @@ setlocale_initialization (void)
} }
} }
/* Return TRUE if module_to_check causes version conflicts.
* If module_to_check is NULL, check the main module.
*/
gboolean
_gtk_module_has_mixed_deps (GModule *module_to_check)
{
GModule *module;
gpointer func;
gboolean result;
if (!module_to_check)
module = g_module_open (NULL, 0);
else
module = module_to_check;
if (g_module_symbol (module, "gtk_progress_get_type", &func))
result = TRUE;
else
result = FALSE;
if (!module_to_check)
g_module_close (module);
return result;
}
static void static void
do_pre_parse_initialization (int *argc, do_pre_parse_initialization (int *argc,
char ***argv) char ***argv)
......
/* GTK - The GIMP Toolkit
* Copyright (C) 2011 Red Hat, Inc.
*
* 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., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
#ifndef __GTK_MAIN_PRIVATE_H__
#define __GTK_MAIN_PRIVATE_H__
#include "gtkmain.h"
G_BEGIN_DECLS
gboolean _gtk_module_has_mixed_deps (GModule *module);
G_END_DECLS
#endif /* __GTK_MAIN_PRIVATE_H__ */
...@@ -42,7 +42,6 @@ ...@@ -42,7 +42,6 @@
#include "gtkbindings.h" #include "gtkbindings.h"
#include "gtkkeyhash.h" #include "gtkkeyhash.h"
#include "gtklabel.h" #include "gtklabel.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkmenubar.h" #include "gtkmenubar.h"
#include "gtkmenuitemprivate.h" #include "gtkmenuitemprivate.h"
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
#include "gtksettings.h" #include "gtksettings.h"
#include "gtkdebug.h" #include "gtkdebug.h"
#include "gtkprivate.h" #include "gtkprivate.h"
#include "gtkmainprivate.h" #include "gtkmodulesprivate.h"
#include "gtkintl.h" #include "gtkintl.h"
#include <gmodule.h> #include <gmodule.h>
...@@ -599,3 +599,29 @@ _gtk_modules_settings_changed (GtkSettings *settings, ...@@ -599,3 +599,29 @@ _gtk_modules_settings_changed (GtkSettings *settings,
new_modules, new_modules,
settings_destroy_notify); settings_destroy_notify);
} }
/* Return TRUE if module_to_check causes version conflicts.
* If module_to_check is NULL, check the main module.
*/
gboolean
_gtk_module_has_mixed_deps (GModule *module_to_check)
{
GModule *module;
gpointer func;
gboolean result;
if (!module_to_check)
module = g_module_open (NULL, 0);
else
module = module_to_check;
if (g_module_symbol (module, "gtk_progress_get_type", &func))
result = TRUE;
else
result = FALSE;
if (!module_to_check)
g_module_close (module);
return result;
}
...@@ -39,6 +39,8 @@ void _gtk_modules_init (gint *argc, ...@@ -39,6 +39,8 @@ void _gtk_modules_init (gint *argc,
void _gtk_modules_settings_changed (GtkSettings *settings, void _gtk_modules_settings_changed (GtkSettings *settings,
const gchar *modules); const gchar *modules);
gboolean _gtk_module_has_mixed_deps (GModule *module);
G_END_DECLS G_END_DECLS
#endif /* __GTK_MODULES_PRIVATE_H__ */ #endif /* __GTK_MODULES_PRIVATE_H__ */
...@@ -25,7 +25,6 @@ ...@@ -25,7 +25,6 @@
#include "gtkoverlay.h" #include "gtkoverlay.h"
#include "gtkbuildable.h" #include "gtkbuildable.h"
#include "gtkscrolledwindow.h" #include "gtkscrolledwindow.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkprivate.h" #include "gtkprivate.h"
......
...@@ -31,7 +31,6 @@ ...@@ -31,7 +31,6 @@
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkintl.h" #include "gtkintl.h"
#include "gtkprivate.h" #include "gtkprivate.h"
#include "gtkmainprivate.h"
#include "gtkmessagedialog.h" #include "gtkmessagedialog.h"
#include "gtktypebuiltins.h" #include "gtktypebuiltins.h"
......
...@@ -30,7 +30,6 @@ ...@@ -30,7 +30,6 @@
#include <stdio.h> #include <stdio.h>
#include <math.h> #include <math.h>
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkorientableprivate.h" #include "gtkorientableprivate.h"
#include "gtkrange.h" #include "gtkrange.h"
......
...@@ -41,7 +41,6 @@ ...@@ -41,7 +41,6 @@
#include "gtkintl.h" #include "gtkintl.h"
#include "gtkbuildable.h" #include "gtkbuildable.h"
#include "gtkbuilderprivate.h" #include "gtkbuilderprivate.h"
#include "gtkmainprivate.h"
#include "a11y/gtkscaleaccessible.h" #include "a11y/gtkscaleaccessible.h"
......
...@@ -31,7 +31,6 @@ ...@@ -31,7 +31,6 @@
#include <string.h> #include <string.h>
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtksizerequest.h" #include "gtksizerequest.h"
#include "gtkplug.h" #include "gtkplug.h"
......
...@@ -38,7 +38,6 @@ ...@@ -38,7 +38,6 @@
#include "gtkbindings.h" #include "gtkbindings.h"
#include "gtkspinbutton.h" #include "gtkspinbutton.h"
#include "gtkentryprivate.h" #include "gtkentryprivate.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtksettings.h" #include "gtksettings.h"
#include "gtkprivate.h" #include "gtkprivate.h"
......
...@@ -51,7 +51,6 @@ ...@@ -51,7 +51,6 @@
#include "gtktextattributes.h" #include "gtktextattributes.h"
#include "gtkmainprivate.h"
#include "gtktexttag.h" #include "gtktexttag.h"
#include "gtktexttypes.h" #include "gtktexttypes.h"
......
...@@ -68,7 +68,6 @@ ...@@ -68,7 +68,6 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "gtkmainprivate.h"
#include "gtktexttag.h" #include "gtktexttag.h"
#include "gtktexttypes.h" #include "gtktexttypes.h"
#include "gtktexttagtable.h" #include "gtktexttagtable.h"
......
...@@ -42,7 +42,7 @@ ...@@ -42,7 +42,7 @@
#include "gtkcontainerprivate.h" #include "gtkcontainerprivate.h"
#include "gtkimage.h" #include "gtkimage.h"
#include "gtklabel.h" #include "gtklabel.h"
#include "gtkmainprivate.h" #include "gtkmain.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkmenu.h" #include "gtkmenu.h"
#include "gtkorientable.h" #include "gtkorientable.h"
......
...@@ -32,7 +32,6 @@ ...@@ -32,7 +32,6 @@
#include "gtksizerequest.h" #include "gtksizerequest.h"
#include "gtkactivatable.h" #include "gtkactivatable.h"
#include "gtkintl.h" #include "gtkintl.h"
#include "gtkmainprivate.h"
#include "gtkprivate.h" #include "gtkprivate.h"
......
...@@ -28,7 +28,6 @@ ...@@ -28,7 +28,6 @@
#include "gtktreednd.h" #include "gtktreednd.h"
#include "gtktreeprivate.h" #include "gtktreeprivate.h"
#include "gtkcellrenderer.h" #include "gtkcellrenderer.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkbuildable.h" #include "gtkbuildable.h"
#include "gtkbutton.h" #include "gtkbutton.h"
......
...@@ -39,7 +39,6 @@ ...@@ -39,7 +39,6 @@
#include "gtkclipboard.h" #include "gtkclipboard.h"
#include "gtkiconfactory.h" #include "gtkiconfactory.h"
#include "gtkintl.h" #include "gtkintl.h"
#include "gtkmainprivate.h"
#include "gtkmarshalers.h" #include "gtkmarshalers.h"
#include "gtkselectionprivate.h" #include "gtkselectionprivate.h"
#include "gtksettingsprivate.h" #include "gtksettingsprivate.h"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment