* Fixed a bug when there was no header selected
[modest] / src / maemo / modest-connection-specific-smtp-edit-window.c
index 4eb22e5..fbd89b7 100644 (file)
@@ -2,8 +2,7 @@
 
 #include "modest-connection-specific-smtp-edit-window.h"
 #include "maemo/modest-maemo-ui-constants.h"
-#include <hildon-widgets/hildon-caption.h>
-#include <hildon-widgets/hildon-number-editor.h>
+#include "modest-hildon-includes.h"
 #include "widgets/modest-serversecurity-combo-box.h"
 #include "widgets/modest-secureauth-combo-box.h"
 #include "widgets/modest-validating-entry.h"
@@ -112,6 +111,7 @@ modest_connection_specific_smtp_edit_window_init (ModestConnectionSpecificSmtpEd
                CONNECTION_SPECIFIC_SMTP_EDIT_WINDOW_GET_PRIVATE (self);
        
        GtkWidget *box = GTK_DIALOG(self)->vbox; /* gtk_vbox_new (FALSE, MODEST_MARGIN_HALF); */
+       gtk_box_set_spacing (GTK_BOX (box), MODEST_MARGIN_NONE);
        gtk_container_set_border_width (GTK_CONTAINER (box), MODEST_MARGIN_HALF);
        
        /* Create a size group to be used by all captions.
@@ -122,6 +122,8 @@ modest_connection_specific_smtp_edit_window_init (ModestConnectionSpecificSmtpEd
        /* The outgoing server widgets: */
        if (!priv->entry_outgoingserver)
                priv->entry_outgoingserver = gtk_entry_new ();
+       /* Auto-capitalization is the default, so let's turn it off: */
+       hildon_gtk_entry_set_input_mode (GTK_ENTRY (priv->entry_outgoingserver), HILDON_GTK_INPUT_MODE_FULL);
        GtkWidget *caption = hildon_caption_new (sizegroup, 
                _("mcen_li_emailsetup_smtp"), priv->entry_outgoingserver, NULL, HILDON_CAPTION_OPTIONAL);
        gtk_widget_show (priv->entry_outgoingserver);
@@ -142,7 +144,9 @@ modest_connection_specific_smtp_edit_window_init (ModestConnectionSpecificSmtpEd
        gtk_widget_show (caption);
        
        /* The username widgets: */     
-       priv->entry_user_username = GTK_WIDGET (easysetup_validating_entry_new ());
+       priv->entry_user_username = GTK_WIDGET (modest_validating_entry_new ());
+       /* Auto-capitalization is the default, so let's turn it off: */
+       hildon_gtk_entry_set_input_mode (GTK_ENTRY (priv->entry_user_username), HILDON_GTK_INPUT_MODE_FULL);
        caption = hildon_caption_new (sizegroup, _("mail_fi_username"), 
                priv->entry_user_username, NULL, HILDON_CAPTION_MANDATORY);
        gtk_widget_show (priv->entry_user_username);
@@ -151,8 +155,8 @@ modest_connection_specific_smtp_edit_window_init (ModestConnectionSpecificSmtpEd
        
        /* Prevent the use of some characters in the username, 
         * as required by our UI specification: */
-       easysetup_validating_entry_set_unallowed_characters_whitespace (
-               EASYSETUP_VALIDATING_ENTRY (priv->entry_user_username));
+       modest_validating_entry_set_unallowed_characters_whitespace (
+               MODEST_VALIDATING_ENTRY (priv->entry_user_username));
        
        /* Set max length as in the UI spec:
         * TODO: The UI spec seems to want us to show a dialog if we hit the maximum. */
@@ -160,6 +164,8 @@ modest_connection_specific_smtp_edit_window_init (ModestConnectionSpecificSmtpEd
        
        /* The password widgets: */     
        priv->entry_user_password = gtk_entry_new ();
+       /* Auto-capitalization is the default, so let's turn it off: */
+       hildon_gtk_entry_set_input_mode (GTK_ENTRY (priv->entry_user_password), HILDON_GTK_INPUT_MODE_FULL);
        gtk_entry_set_visibility (GTK_ENTRY (priv->entry_user_password), FALSE);
        /* gtk_entry_set_invisible_char (GTK_ENTRY (priv->entry_user_password), '*'); */
        caption = hildon_caption_new (sizegroup,