[gnome-control-center] [default-applications] return an empty string for the custom web item



commit c1ee031d153abb302bd1e9223dae8a7b2a4849e1
Author: Thomas Wood <thos gnome org>
Date:   Mon Dec 7 22:46:02 2009 +0000

    [default-applications] return an empty string for the custom web item
    
    This prevents the combo box from snapping back to the previous item

 capplets/default-applications/gnome-da-capplet.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/capplets/default-applications/gnome-da-capplet.c b/capplets/default-applications/gnome-da-capplet.c
index 64d9bff..438ee13 100644
--- a/capplets/default-applications/gnome-da-capplet.c
+++ b/capplets/default-applications/gnome-da-capplet.c
@@ -492,9 +492,10 @@ web_combo_conv_from_widget (GConfPropertyEditor *peditor, const GConfValue *valu
     if (!item)
     {
         /* if item was not found, this is probably the "Custom" item */
-        gchar *c = gconf_client_get_string (capplet->gconf, DEFAULT_APPS_KEY_HTTP_EXEC, NULL);
-        gconf_value_set_string (ret, (c != NULL) ? c : "");
-        g_free (c);
+        /* XXX: returning "" as the value here is not ideal, but required to
+         * prevent the combo box from jumping back to the previous value if the
+         * user has selected Custom */
+        gconf_value_set_string (ret, "");
         return ret;
     }
     else



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