diff options
author | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-10-05 19:57:30 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@gnome-db.org> | 2011-10-05 19:57:30 +0800 |
commit | 4ec46cc05fcb94d181fb9c2412984a1446647c85 (patch) | |
tree | d16ce30e77dd539c03509237dd4c723d46aea97a /modules/mail/em-network-prefs.c | |
parent | 5ea7e23aef0c239af2600c95419ba0bda0f08b3c (diff) | |
parent | 19163c2b71e6128fc9b32287b99b1f4422324c2d (diff) | |
download | gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.tar gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.tar.gz gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.tar.bz2 gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.tar.lz gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.tar.xz gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.tar.zst gsoc2013-evolution-4ec46cc05fcb94d181fb9c2412984a1446647c85.zip |
Merge from master
Diffstat (limited to 'modules/mail/em-network-prefs.c')
-rw-r--r-- | modules/mail/em-network-prefs.c | 35 |
1 files changed, 16 insertions, 19 deletions
diff --git a/modules/mail/em-network-prefs.c b/modules/mail/em-network-prefs.c index 242c84993e..64fe23e7f9 100644 --- a/modules/mail/em-network-prefs.c +++ b/modules/mail/em-network-prefs.c @@ -148,12 +148,11 @@ emnp_set_sensitiveness (EMNetworkPrefs *prefs, gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_http_port, sensitivity); gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_https_host, sensitivity); gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_https_port, sensitivity); -#if 0 gtk_widget_set_sensitive ((GtkWidget *) prefs->socks_host, sensitivity); gtk_widget_set_sensitive ((GtkWidget *) prefs->socks_port, sensitivity); gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_socks_host, sensitivity); gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_socks_port, sensitivity); -#endif + state = sensitivity && gtk_toggle_button_get_active (prefs->use_auth); gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_auth_user, state); gtk_widget_set_sensitive ((GtkWidget *) prefs->lbl_auth_pwd, state); @@ -389,13 +388,17 @@ em_network_prefs_construct (EMNetworkPrefs *prefs) prefs->manual_proxy = GTK_TOGGLE_BUTTON (e_builder_get_widget (prefs->builder, "rdoManualProxy")); prefs->http_host = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtHttpHost")); prefs->https_host = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtHttpsHost")); + prefs->socks_host = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtSocksHost")); prefs->ignore_hosts = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtIgnoreHosts")); prefs->http_port = GTK_SPIN_BUTTON (e_builder_get_widget (prefs->builder, "spnHttpPort")); prefs->https_port = GTK_SPIN_BUTTON (e_builder_get_widget (prefs->builder, "spnHttpsPort")); + prefs->socks_port = GTK_SPIN_BUTTON (e_builder_get_widget (prefs->builder, "spnSocksPort")); prefs->lbl_http_host = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblHttpHost")); prefs->lbl_http_port = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblHttpPort")); prefs->lbl_https_host = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblHttpsHost")); prefs->lbl_https_port = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblHttpsPort")); + prefs->lbl_socks_host = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblSocksHost")); + prefs->lbl_socks_port = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblSocksPort")); prefs->lbl_ignore_hosts = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblIgnoreHosts")); prefs->use_auth = GTK_TOGGLE_BUTTON (e_builder_get_widget (prefs->builder, "chkUseAuth")); toggle_button_init (prefs, prefs->use_auth, GCONF_E_USE_AUTH_KEY); @@ -404,17 +407,6 @@ em_network_prefs_construct (EMNetworkPrefs *prefs) prefs->auth_user = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtAuthUser")); prefs->auth_pwd = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtAuthPwd")); -#if 0 - prefs->socks_host = GTK_ENTRY (e_builder_get_widget (prefs->builder, "txtSocksHost")); - prefs->socks_port = GTK_SPIN_BUTTON (e_builder_get_widget (prefs->builder, "spnSocksPort")); - prefs->lbl_socks_host = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblSocksHost")); - prefs->lbl_socks_port = GTK_LABEL (e_builder_get_widget (prefs->builder, "lblSocksPort")); - g_signal_connect (prefs->socks_host, "changed", - G_CALLBACK (widget_entry_changed_cb), GCONF_E_SOCKS_HOST_KEY); - g_signal_connect (prefs->socks_port, "value_changed", - G_CALLBACK (widget_entry_changed_cb), GCONF_E_SOCKS_PORT_KEY); -#endif - /* Manual proxy options */ g_signal_connect (prefs->http_host, "changed", G_CALLBACK (widget_entry_changed_cb), @@ -431,6 +423,12 @@ em_network_prefs_construct (EMNetworkPrefs *prefs) g_signal_connect (prefs->https_port, "value_changed", G_CALLBACK (widget_entry_changed_cb), (gpointer) GCONF_E_HTTPS_PORT_KEY); + g_signal_connect (prefs->socks_host, "changed", + G_CALLBACK (widget_entry_changed_cb), + (gpointer) GCONF_E_SOCKS_HOST_KEY); + g_signal_connect (prefs->socks_port, "value_changed", + G_CALLBACK (widget_entry_changed_cb), + (gpointer) GCONF_E_SOCKS_PORT_KEY); g_signal_connect (prefs->auth_user, "changed", G_CALLBACK (widget_entry_changed_cb), (gpointer) GCONF_E_AUTH_USER_KEY); @@ -458,6 +456,10 @@ em_network_prefs_construct (EMNetworkPrefs *prefs) gtk_entry_set_text (prefs->https_host, buf ? buf : ""); g_free (buf); + buf = gconf_client_get_string (prefs->gconf, GCONF_E_SOCKS_HOST_KEY, NULL); + gtk_entry_set_text (prefs->socks_host, buf ? buf : ""); + g_free (buf); + buf = NULL; ignore = gconf_client_get_list (prefs->gconf, GCONF_E_IGNORE_HOSTS_KEY, GCONF_VALUE_STRING, NULL); if (ignore) { @@ -502,14 +504,9 @@ em_network_prefs_construct (EMNetworkPrefs *prefs) port = gconf_client_get_int (prefs->gconf, GCONF_E_HTTPS_PORT_KEY, NULL); gtk_spin_button_set_value (prefs->https_port, (gdouble) port); -#if 0 - buf = gconf_client_get_string (prefs->gconf, GCONF_E_SOCKS_HOST_KEY, NULL); - gtk_entry_set_text (prefs->socks_host, buf ? buf : ""); - g_free (buf); - port = gconf_client_get_int (prefs->gconf, GCONF_E_SOCKS_PORT_KEY, NULL); gtk_spin_button_set_value (prefs->socks_port, (gdouble) port); -#endif + emnp_set_markups (prefs); if (val == NETWORK_PROXY_DIRECT_CONNECTION || |