[gnome-control-center] color: Connect to the profile before doing cd_profile_equal -- we use the ID not the path



commit a44d36f9932008499e44443b512319e33f4fd615
Author: Richard Hughes <richard hughsie com>
Date:   Tue May 31 10:43:31 2011 +0100

    color: Connect to the profile before doing cd_profile_equal -- we use the ID not the path

 panels/color/cc-color-panel.c |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/panels/color/cc-color-panel.c b/panels/color/cc-color-panel.c
index 6413693..b97ea4e 100644
--- a/panels/color/cc-color-panel.c
+++ b/panels/color/cc-color-panel.c
@@ -347,10 +347,6 @@ gcm_prefs_add_profiles_suitable_for_devices (CcColorPanel *prefs,
     {
       profile_tmp = g_ptr_array_index (profile_array, i);
 
-      /* don't add the current profile */
-      if (profile != NULL && cd_profile_equal (profile, profile_tmp))
-        continue;
-
       /* get properties */
       ret = cd_profile_connect_sync (profile_tmp,
                                      priv->cancellable,
@@ -362,6 +358,10 @@ gcm_prefs_add_profiles_suitable_for_devices (CcColorPanel *prefs,
           goto out;
         }
 
+      /* don't add the current profile */
+      if (profile != NULL && cd_profile_equal (profile, profile_tmp))
+        continue;
+
       /* only add correct types */
       ret = gcm_prefs_is_profile_suitable_for_device (profile_tmp,
                                                       priv->current_device);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]