From d1ad5d6b46225725b97e425cdc31675d29676e5d Mon Sep 17 00:00:00 2001 From: Dmitry Shachnev Date: Fri, 17 May 2013 21:59:33 +0400 Subject: Do not call g_type_init() with GLib >= 2.36 g_type_init() is deprecated and the type system is now initialized automatically. Change-Id: I5bf5702136cc948dea0a55676dfee2486f12ca00 Reviewed-by: J-P Nurmi --- src/widgets/styles/qgtkstyle_p.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/widgets/styles/qgtkstyle_p.cpp b/src/widgets/styles/qgtkstyle_p.cpp index a53a961a89..769d822108 100644 --- a/src/widgets/styles/qgtkstyle_p.cpp +++ b/src/widgets/styles/qgtkstyle_p.cpp @@ -641,7 +641,9 @@ QString QGtkStylePrivate::getGConfString(const QString &value, const QString &fa { QString retVal = fallback; if (resolveGConf()) { +#if !defined(GLIB_VERSION_2_36) g_type_init(); +#endif GConfClient* client = gconf_client_get_default(); GError *err = 0; char *str = gconf_client_get_string(client, qPrintable(value), &err); @@ -660,7 +662,9 @@ bool QGtkStylePrivate::getGConfBool(const QString &key, bool fallback) { bool retVal = fallback; if (resolveGConf()) { +#if !defined(GLIB_VERSION_2_36) g_type_init(); +#endif GConfClient* client = gconf_client_get_default(); GError *err = 0; bool result = gconf_client_get_bool(client, qPrintable(key), &err); -- cgit v1.2.3