filebrowser: Fix g_settings_schema_source_lookup usage

This commit is contained in:
Stefano Karapetsas 2014-06-06 20:16:24 +02:00
parent ca9fdb4cef
commit 1f4945e1ff
1 changed files with 4 additions and 1 deletions

View File

@ -624,6 +624,7 @@ impl_activate (PlumaPlugin * plugin, PlumaWindow * window)
PlumaFileBrowserStore * store;
gchar *data_dir;
GSettingsSchemaSource *schema_source;
GSettingsSchema *schema;
data = g_new0 (PlumaFileBrowserPluginData, 1);
@ -690,9 +691,11 @@ impl_activate (PlumaPlugin * plugin, PlumaWindow * window)
/* Install caja preferences */
schema_source = g_settings_schema_source_get_default();
if (g_settings_schema_source_lookup (schema_source, CAJA_SCHEMA, FALSE)) {
schema = g_settings_schema_source_lookup (schema_source, CAJA_SCHEMA, FALSE);
if (schema != NULL) {
data->caja_settings = g_settings_new (CAJA_SCHEMA);
install_caja_prefs (data);
g_settings_schema_unref (schema);
}
/* Connect signals to store the last visited location */