[yast-commit] r60547 - in /trunk/mail/src: Mail.ycp ui.ycp
Author: varkoly Date: Wed Jan 27 12:44:45 2010 New Revision: 60547 URL: http://svn.opensuse.org/viewcvs/yast?rev=60547&view=rev Log: Make smtp_use_TLS ternary Modified: trunk/mail/src/Mail.ycp trunk/mail/src/ui.ycp Modified: trunk/mail/src/Mail.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/mail/src/Mail.ycp?rev=60547&r1=60546&r2=60547&view=diff ============================================================================== --- trunk/mail/src/Mail.ycp (original) +++ trunk/mail/src/Mail.ycp Wed Jan 27 12:44:45 2010 @@ -103,7 +103,7 @@ /** * Do the MTA use TLS for sending the email. */ - global boolean smtp_use_TLS = true; + global string smtp_use_TLS = "yes"; /** * Mail will appear to come from this domain. Applies also for the @@ -447,7 +447,7 @@ } else if (mta == `postfix) { - smtp_use_TLS = ( (string) SCR::Read (.sysconfig.postfix.POSTFIX_SMTP_TLS_CLIENT) == "yes" ); + smtp_use_TLS = (string) SCR::Read (.sysconfig.postfix.POSTFIX_SMTP_TLS_CLIENT); outgoing_mail_server = (string) SCR::Read (.sysconfig.postfix.POSTFIX_RELAYHOST); } @@ -783,14 +783,7 @@ else if (mta == `postfix) { SCR::Write (.sysconfig.postfix.POSTFIX_RELAYHOST, outgoing_mail_server); - if( smtp_use_TLS ) - { - SCR::Write (.sysconfig.postfix.POSTFIX_SMTP_TLS_CLIENT, "yes"); - } - else - { - SCR::Write (.sysconfig.postfix.POSTFIX_SMTP_TLS_CLIENT, "no"); - } + SCR::Write (.sysconfig.postfix.POSTFIX_SMTP_TLS_CLIENT, smtp_use_TLS); } else { Modified: trunk/mail/src/ui.ycp URL: http://svn.opensuse.org/viewcvs/yast/trunk/mail/src/ui.ycp?rev=60547&r1=60546&r2=60547&view=diff ============================================================================== --- trunk/mail/src/ui.ycp (original) +++ trunk/mail/src/ui.ycp Wed Jan 27 12:44:45 2010 @@ -342,6 +342,10 @@ define symbol OutgoingDialog () ``{ Wizard::SetScreenShotName ("mail-21-outgoing"); + boolean TLSnone = ( Mail::smtp_use_TLS == "no" ); + boolean TLSuse = ( Mail::smtp_use_TLS == "yes" ); + boolean TLSmust = ( Mail::smtp_use_TLS == "must" ); + // what buttons can be used to leave this dialog //(except the std wizarding ones) list<symbol> buttons = []; @@ -357,7 +361,13 @@ `VBox ( WJ_MakeWidget (`outgoing_mail_server), // TLS - `CheckBox( `id(`tls), _("The server use &TLS"), Mail::smtp_use_TLS ), + `RadioButtonGroup(`id(`TLS), _("The server use &TLS") + `HBox( + `Left(`RadioButton(`id("no"), _("No"), TLSnone)), + `Left(`RadioButton(`id("yes"), _("Use"), TLSuse)), + `Left(`RadioButton(`id("must"), _("Enforce"),TLSmust)) + ) + ), // Translators: button // TODO ... `PushButton (`id(`outgoing_details), _("&Masquerading")), -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
varkoly@svn.opensuse.org