diff --git a/capplets/network/gnome-network-properties.c b/capplets/network/gnome-network-properties.c
index d874146..988f247 100644
--- a/capplets/network/gnome-network-properties.c
+++ b/capplets/network/gnome-network-properties.c
@@ -79,10 +79,15 @@ enum {
 
 #define GNOMECC_GNP_UI_FILE (GNOMECC_UI_DIR "/gnome-network-properties.ui")
 
+#define NUMBER_OF_PROTOCOLS 4
+
 static GtkWidget *details_dialog = NULL;
 static GSList *ignore_hosts = NULL;
 static GtkTreeModel *model = NULL;
 
+static unsigned int entry_handler = 0;
+static unsigned int port_handler  = 0;
+
 static GtkTreeModel *
 create_listmodel(void)
 {
@@ -922,6 +927,93 @@ cb_delete_button_clicked (GtkWidget *button,
 	g_object_unref (client);
 }
 
+/* When using the same proxy for all protocols, updates every host_entry
+ * as the user types along */
+static gboolean
+synchronize_hosts (GtkWidget *widget,
+			GdkEventKey *event,
+			gpointer data)
+{
+	char *hosts[NUMBER_OF_PROTOCOLS] = {
+		"http_host_entry", 
+		"secure_host_entry", 
+		"ftp_host_entry", 
+		"socks_host_entry"};
+	int i;
+	GtkBuilder *builder;
+	GtkEntry *current_entry;
+	const gchar *http_host;
+
+	builder = GTK_BUILDER (data);
+	current_entry = GTK_ENTRY (gtk_builder_get_object (builder, "http_host_entry"));
+	http_host = gtk_entry_get_text (current_entry);
+
+	for (i = 1; i < NUMBER_OF_PROTOCOLS; i++)
+	{
+		current_entry = GTK_ENTRY (gtk_builder_get_object (builder, hosts[i]));
+		gtk_entry_set_text (current_entry, http_host);
+	} 
+
+	return FALSE;
+}
+
+/* When using the same proxy for all protocols, copies the value of the
+ * http port to the other spinbuttons */
+static void
+synchronize_ports (GtkSpinButton *spinbutton,
+            gpointer data)
+{
+	gdouble http_port;
+	GtkSpinButton *current_spin_button;
+	char *ports[NUMBER_OF_PROTOCOLS] = {
+		"http_port_spinbuton",
+		"secure_port_spinbutton",
+		"ftp_port_spinbutton",
+		"socks_port_spinbutton"};
+	int i;
+	GtkBuilder *builder;
+
+	builder = GTK_BUILDER (data);
+	current_spin_button = GTK_SPIN_BUTTON (
+		gtk_builder_get_object (builder, "http_port_spinbutton"));
+	http_port = gtk_spin_button_get_value (current_spin_button);
+
+	for (i = 1; i < NUMBER_OF_PROTOCOLS; i++)
+	{
+		current_spin_button = GTK_SPIN_BUTTON (
+			gtk_builder_get_object (builder, ports[i]));
+		gtk_spin_button_set_value (current_spin_button, http_port);
+	}
+}
+
+/* Synchronizes all hosts and ports */
+static void
+synchronize_entries (GtkBuilder *builder)
+{
+	entry_handler = g_signal_connect (
+		gtk_builder_get_object (builder, "http_host_entry"),
+		"key-release-event", 
+		G_CALLBACK (synchronize_hosts), 
+		builder);
+	port_handler = g_signal_connect (
+		gtk_builder_get_object (builder, "http_port_spinbutton"),
+		"value-changed", 
+		G_CALLBACK (synchronize_ports), 
+		builder);
+}
+
+/* Unsynchronize hosts and ports */
+static void
+unsynchronize_entries (GtkBuilder *builder)
+{
+	g_signal_handler_disconnect (
+		gtk_builder_get_object (builder, "http_host_entry"),
+		entry_handler);
+	g_signal_handler_disconnect (
+		gtk_builder_get_object (builder, "http_port_spinbutton"),
+		port_handler);
+}
+
 static void
 cb_use_same_proxy_checkbutton_clicked (GtkWidget *checkbutton,
 				       GtkBuilder *builder)
@@ -968,6 +1060,9 @@ cb_use_same_proxy_checkbutton_clicked (GtkWidget *checkbutton,
 
 		gconf_client_set_string (client, SOCKS_PROXY_HOST_KEY, http_proxy, NULL);
 		gconf_client_set_int (client, SOCKS_PROXY_PORT_KEY, http_port, NULL);
+
+		/* Synchronze entries */
+		synchronize_entries (builder);	
 	}
 	else
 	{
@@ -988,6 +1083,9 @@ cb_use_same_proxy_checkbutton_clicked (GtkWidget *checkbutton,
 		gconf_client_set_int (client, SOCKS_PROXY_PORT_KEY,
 			gconf_client_get_int (client, OLD_SOCKS_PROXY_PORT_KEY, NULL), NULL);
 		g_free (host);
+
+		/* Hosts and ports should not be synchronized any more */
+		unsynchronize_entries (builder);
 	}
 
 	/* Set the proxy entries insensitive if we are using the same proxy for all */
@@ -1107,6 +1205,8 @@ connect_sensitivity_signals (GtkBuilder *builder, GSList *mode_group)
 	}
 }
 
+
+
 static void
 setup_dialog (GtkBuilder *builder)
 {
@@ -1222,7 +1322,8 @@ setup_dialog (GtkBuilder *builder)
 			_gtk_builder_get_widget (builder, "socks_port_spinbutton"),
 			NULL));
 
-	/* Set the proxy entries insensitive if we are using the same proxy for all */
+	/* Set the proxy entries insensitive if we are using the same proxy for all,
+	   and make sure they are all synchronized */
 	if (gconf_client_get_bool (client, USE_SAME_PROXY_KEY, NULL))
 	{
 		gtk_widget_set_sensitive (_gtk_builder_get_widget (builder, "secure_host_entry"), FALSE);
@@ -1231,6 +1332,8 @@ setup_dialog (GtkBuilder *builder)
 		gtk_widget_set_sensitive (_gtk_builder_get_widget (builder, "ftp_port_spinbutton"), FALSE);
 		gtk_widget_set_sensitive (_gtk_builder_get_widget (builder, "socks_host_entry"), FALSE);
 		gtk_widget_set_sensitive (_gtk_builder_get_widget (builder, "socks_port_spinbutton"), FALSE);
+
+		synchronize_entries (builder);
 	}
 
 	/* Autoconfiguration */
@@ -1256,6 +1359,7 @@ setup_dialog (GtkBuilder *builder)
 			  "activate", G_CALLBACK (cb_add_url), builder);
 	g_signal_connect (gtk_builder_get_object (builder, "button_remove_url"),
 			  "clicked", G_CALLBACK (cb_remove_url), builder);
+
 }
 
 int
