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 <jpnurmi@digia.com>
This commit is contained in:
Dmitry Shachnev 2013-05-17 21:59:33 +04:00 committed by The Qt Project
parent 77c0216369
commit d1ad5d6b46

View File

@ -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);