From c9647e530d630e5ca10d2c8c4bb5d4552a5db0cf Mon Sep 17 00:00:00 2001 From: Richard Hughes Date: Thu, 13 Oct 2011 15:57:55 +0100 Subject: [PATCH] color: Do not show standard colorspaces in the 'Add profile' UI NOTE: You need colord >= 0.1.4 and shared-color-profiles >= 0.1.5 for this to work. --- panels/color/cc-color-panel.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/panels/color/cc-color-panel.c b/panels/color/cc-color-panel.c index 39fdbcb5d..5175ea764 100644 --- a/panels/color/cc-color-panel.c +++ b/panels/color/cc-color-panel.c @@ -291,6 +291,9 @@ static gboolean gcm_prefs_is_profile_suitable_for_device (CdProfile *profile, CdDevice *device) { +#if CD_CHECK_VERSION(0,1,14) + const gchar *data_source; +#endif CdProfileKind profile_kind_tmp; CdProfileKind profile_kind; CdColorspace profile_colorspace; @@ -311,6 +314,14 @@ gcm_prefs_is_profile_suitable_for_device (CdProfile *profile, if (profile_kind_tmp != profile_kind) goto out; +#if CD_CHECK_VERSION(0,1,14) + /* ignore the colorspace profiles */ + data_source = cd_profile_get_metadata_item (profile, + CD_PROFILE_METADATA_DATA_SOURCE); + if (g_strcmp0 (data_source, CD_PROFILE_METADATA_DATA_SOURCE_STANDARD) == 0) + goto out; +#endif + /* success */ ret = TRUE; out: