[evolution/gnome-2-28] Support for Anjal to have provider specific options in acc editor.



commit c4b783da288af2666d16767c89e6e8d8df8326f6
Author: Srinivasa Ragavan <sragavan novell com>
Date:   Thu Aug 27 10:44:53 2009 +0530

    Support for Anjal to have provider specific options in acc editor.

 mail/em-account-editor.c |   28 +++++++++++++++++++++++++---
 1 files changed, 25 insertions(+), 3 deletions(-)
---
diff --git a/mail/em-account-editor.c b/mail/em-account-editor.c
index 0c7e978..5554f26 100644
--- a/mail/em-account-editor.c
+++ b/mail/em-account-editor.c
@@ -2190,8 +2190,24 @@ emae_receive_options_item (EConfig *ec, EConfigItem *item, GtkWidget *parent, Gt
 	    || emae->priv->source.provider->extra_conf == NULL)
 		return NULL;
 
-	if (old)
+	if (old) {
+		if (emae->type == EMAE_PAGES) {
+			GtkWidget *box = gtk_hbox_new (FALSE, 12);
+			gtk_widget_reparent (old, box);
+			gtk_widget_show(box);
+			gtk_box_set_child_packing ((GtkBox *)box, old, TRUE, TRUE, 12, GTK_PACK_START);			
+			gtk_box_pack_end ((GtkBox *)emae->pages[2], box, FALSE, FALSE, 0);
+		}
 		return old;
+	}
+
+	if (emae->type == EMAE_PAGES)  {
+		GtkWidget *box = gtk_hbox_new (FALSE, 12);
+		gtk_widget_reparent (parent, box);
+		gtk_widget_show(box);
+		gtk_box_set_child_packing ((GtkBox *)box, parent, TRUE, TRUE, 12, GTK_PACK_START);
+		gtk_box_pack_start ((GtkBox *)emae->pages[2], box, FALSE, FALSE, 0);
+	}
 
 	/* We have to add the automatic mail check item with the rest of the receive options */
 	row = ((GtkTable *)parent)->nrows;
@@ -2233,6 +2249,13 @@ emae_receive_options_extra_item (EConfig *ec, EConfigItem *eitem, GtkWidget *par
 	if (emae->priv->source.provider == NULL
 	    || emae->priv->source.provider->extra_conf == NULL)
 		return NULL;
+	if (emae->type == EMAE_PAGES) {
+		GtkWidget *box = gtk_hbox_new (FALSE, 12);
+		gtk_widget_reparent (parent, box);
+		gtk_widget_show(box);
+		gtk_box_set_child_packing ((GtkBox *)box, parent, TRUE, TRUE, 12, GTK_PACK_START);
+		gtk_box_pack_start ((GtkBox *)emae->pages[2], box, FALSE, FALSE, 0);
+	}
 
 	entries = emae->priv->source.provider->extra_conf;
 	for (i=0;entries && entries[i].type != CAMEL_PROVIDER_CONF_END;i++)
@@ -2244,7 +2267,6 @@ emae_receive_options_extra_item (EConfig *ec, EConfigItem *eitem, GtkWidget *par
 	return NULL;
 section:
 	d (printf ("Building extra section '%s'\n", eitem->path));
-
 	url = emae_account_url (emae, emae_service_info[service->type].account_uri_key);
 	item->extra_table = g_hash_table_new (g_str_hash, g_str_equal);
 	extra = g_hash_table_new (g_str_hash, g_str_equal);
@@ -2377,7 +2399,7 @@ emae_send_page (EConfig *ec, EConfigItem *item, GtkWidget *parent, GtkWidget *ol
 
 	w = glade_xml_get_widget (xml, item->label);
 	if (emae->type == EMAE_PAGES) {
-		gtk_box_pack_start ((GtkBox *)emae->pages[2], w, TRUE, TRUE, 0);
+		gtk_box_pack_start ((GtkBox *)emae->pages[3], w, TRUE, TRUE, 0);
 	} else if (((EConfig *)gui->config)->type == E_CONFIG_DRUID) {
 		GladeXML *druidxml;
 		GtkWidget *page;



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