kov changed gksu/trunk/ChangeLog, gksu/trunk/gksu/gksu.c

Gustavo Noronha kov at costa.debian.org
Wed Oct 26 12:49:48 UTC 2005


Mensagem de log: 
	* gksu/gksu.c:
	- more logic problem fixes, this time with the 
	  display-no-pass-info gconf key - the meaning of the
	  gconf key bool value and the check button bool value
	  are inverted, so we need to special case it



-----


Modified: gksu/trunk/ChangeLog
===================================================================
--- gksu/trunk/ChangeLog	2005-10-26 12:35:32 UTC (rev 463)
+++ gksu/trunk/ChangeLog	2005-10-26 12:49:47 UTC (rev 464)
@@ -1,6 +1,12 @@
 2005-10-26  Gustavo Noronha Silva  <kov at debian.org>
 
 	* gksu/gksu.c:
+	- more logic problem fixes, this time with the 
+	  display-no-pass-info gconf key - the meaning of the
+	  gconf key bool value and the check button bool value
+	  are inverted, so we need to special case it
+
+	* gksu/gksu.c:
 	- only try_gnome_keyring if gksu_context_try_need_password
 	  returns TRUE
 

Modified: gksu/trunk/gksu/gksu.c
===================================================================
--- gksu/trunk/gksu/gksu.c	2005-10-26 12:35:32 UTC (rev 463)
+++ gksu/trunk/gksu/gksu.c	2005-10-26 12:49:47 UTC (rev 464)
@@ -839,6 +839,14 @@
       else
 	gconf_client_set_string (gconf_client, key, "default", NULL);
     }
+  else if (!strcmp (key_name, "display-no-pass-info"))
+    {
+      /* the meaning of the key is the exact opposite of the meaning
+	 of the answer - when the check button is checked the key must
+	 be off
+      */
+      gconf_client_set_bool (gconf_client, key, !toggled, NULL);
+    }
   else
     gconf_client_set_bool (gconf_client, key, toggled, NULL);
 
@@ -856,7 +864,7 @@
   toggled = gconf_client_get_bool (gconf_client, BASE_PATH "display-no-pass-info", NULL);
 
   /* configuration tells us to not show this message */
-  if (toggled)
+  if (!toggled)
     return;
 
   dialog = gtk_message_dialog_new_with_markup (NULL, 0, 
@@ -885,7 +893,6 @@
   check_button = gtk_check_button_new_with_mnemonic (_("Do _not display this message again"));
   g_signal_connect (G_OBJECT(check_button), "toggled", 
 		    G_CALLBACK(cb_toggled_cb), "display-no-pass-info");
-  gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON(check_button), toggled);
   gtk_container_add (GTK_CONTAINER(alignment), check_button);
 
   gtk_widget_show_all (dialog);




More information about the gksu-commits mailing list