X-Git-Url: http://git.maemo.org/git/?p=modest;a=blobdiff_plain;f=src%2Fhildon2%2Fmodest-maemo-security-options-view.c;h=65bf10cf95bae01f1b94c1176927db6d474b7605;hp=209e3ebd116a42224634f43e29152cddc3ae1cad;hb=cc73115b2210bc9de90c00e1578c35fcc41e4c7c;hpb=17319d5700c0f40e765d1128f20f3ffa86602932 diff --git a/src/hildon2/modest-maemo-security-options-view.c b/src/hildon2/modest-maemo-security-options-view.c index 209e3eb..65bf10c 100644 --- a/src/hildon2/modest-maemo-security-options-view.c +++ b/src/hildon2/modest-maemo-security-options-view.c @@ -221,12 +221,23 @@ on_entry_changed (GtkEditable *editable, } else { missing = FALSE; } + + if (!missing && ppriv->full && !modest_number_editor_is_valid (MODEST_NUMBER_EDITOR (ppriv->port_view))) + missing = TRUE; /* Emit a signal to notify if mandatory data is missing */ g_signal_emit_by_name (G_OBJECT (self), "missing_mandatory_data", missing, NULL); } +void +on_valid_changed (ModestNumberEditor *editor, + gboolean valid, + ModestSecurityOptionsView *self) +{ + on_entry_changed (NULL, (gpointer) self); +} + static void create_outgoing_security (ModestSecurityOptionsView* self, GtkSizeGroup *title_size_group, @@ -313,6 +324,8 @@ create_outgoing_security (ModestSecurityOptionsView* self, G_CALLBACK (on_auth_changed), self); g_signal_connect (G_OBJECT (ppriv->user_entry), "changed", G_CALLBACK (on_entry_changed), self); + g_signal_connect (G_OBJECT (ppriv->port_view), "valid-changed", + G_CALLBACK (on_valid_changed), self); } /* Initialize widgets */