diff -Nru unity-control-center-15.04.0+16.04.20160413/debian/changelog unity-control-center-15.04.0+16.04.20160705/debian/changelog --- unity-control-center-15.04.0+16.04.20160413/debian/changelog 2016-07-11 18:40:20.000000000 +0000 +++ unity-control-center-15.04.0+16.04.20160705/debian/changelog 2016-07-11 18:40:20.000000000 +0000 @@ -1,3 +1,14 @@ +unity-control-center (15.04.0+16.04.20160705-0ubuntu1) xenial; urgency=medium + + [ Trent Lloyd ] + * Fix crash when application supports no mime-type (LP: #1304388) + + [ Marco Trevisan (Treviño) ] + * CcAppearancePanel: read COMPIZ_CONFIG_PROFILE value to choose the + right settings path (LP: #1598770) + + -- Marco Trevisan (Treviño) Tue, 05 Jul 2016 14:48:55 +0000 + unity-control-center (15.04.0+16.04.20160413-0ubuntu3) xenial; urgency=medium * panels/bluetooth/gnome-bluetooth/wizard/main.c: diff -Nru unity-control-center-15.04.0+16.04.20160413/panels/appearance/cc-appearance-panel.c unity-control-center-15.04.0+16.04.20160705/panels/appearance/cc-appearance-panel.c --- unity-control-center-15.04.0+16.04.20160413/panels/appearance/cc-appearance-panel.c 2016-04-13 22:16:54.000000000 +0000 +++ unity-control-center-15.04.0+16.04.20160705/panels/appearance/cc-appearance-panel.c 2016-07-05 14:48:34.000000000 +0000 @@ -99,7 +99,7 @@ }; #define UNITY_GSETTINGS_SCHEMA "org.compiz.unityshell" -#define UNITY_PROFILE_PATH "/org/compiz/profiles/unity/plugins/" +#define UNITY_PROFILE_PATH "/org/compiz/profiles/%s/plugins/" #define UNITY_GSETTINGS_PATH UNITY_PROFILE_PATH"unityshell/" #define UNITY_ICONSIZE_KEY "icon-size" #define UNITY_LAUNCHERSENSITIVITY_KEY "edge-responsiveness" @@ -1848,6 +1848,19 @@ /* */ +static gchar * +compiz_profile_gsettings_path (const gchar *path) +{ + const gchar *profile = "unity"; + + if (g_strcmp0 (g_getenv ("COMPIZ_CONFIG_PROFILE"), "ubuntu-lowgfx") == 0) + { + profile = "unity-lowgfx"; + } + + return g_strdup_printf (path, profile); +} + static void setup_unity_settings (CcAppearancePanel *self) { @@ -1858,6 +1871,7 @@ GtkScale* launcher_sensitivity_scale; GSettingsSchema *schema; GSettingsSchemaSource* source; + gchar *settings_path; source = g_settings_schema_source_get_default (); schema = g_settings_schema_source_lookup (source, UNITY_OWN_GSETTINGS_SCHEMA, TRUE); @@ -1875,14 +1889,18 @@ schema = g_settings_schema_source_lookup (source, UNITY_GSETTINGS_SCHEMA, TRUE); if (schema) { - priv->unity_settings = g_settings_new_with_path (UNITY_GSETTINGS_SCHEMA, UNITY_GSETTINGS_PATH); + settings_path = compiz_profile_gsettings_path (UNITY_GSETTINGS_PATH); + priv->unity_settings = g_settings_new_with_path (UNITY_GSETTINGS_SCHEMA, settings_path); g_settings_schema_unref (schema); + g_free (settings_path); } schema = g_settings_schema_source_lookup (source, COMPIZCORE_GSETTINGS_SCHEMA, TRUE); if (schema) { - priv->compizcore_settings = g_settings_new_with_path (COMPIZCORE_GSETTINGS_SCHEMA, COMPIZCORE_GSETTINGS_PATH); + settings_path = compiz_profile_gsettings_path (COMPIZCORE_GSETTINGS_PATH); + priv->compizcore_settings = g_settings_new_with_path (COMPIZCORE_GSETTINGS_SCHEMA, settings_path); g_settings_schema_unref (schema); + g_free (settings_path); } if (!priv->unity_settings || !priv->compizcore_settings || !priv->unity_own_settings || !priv->unity_launcher_settings) diff -Nru unity-control-center-15.04.0+16.04.20160413/panels/info/cc-info-panel.c unity-control-center-15.04.0+16.04.20160705/panels/info/cc-info-panel.c --- unity-control-center-15.04.0+16.04.20160413/panels/info/cc-info-panel.c 2016-04-13 22:16:54.000000000 +0000 +++ unity-control-center-15.04.0+16.04.20160705/panels/info/cc-info-panel.c 2016-07-05 14:48:34.000000000 +0000 @@ -813,7 +813,7 @@ pattern = g_pattern_spec_new (app_data->extra_type_filter); mime_types = g_app_info_get_supported_types (info); - for (i = 0; mime_types[i]; i++) + for (i = 0; mime_types && mime_types[i]; i++) { if (!g_pattern_match_string (pattern, mime_types[i])) continue;