dojo.provide("c11n.allDomain.js.widget.mail.option.Forwarding"); dojo["require"]("iwc.widget.mail.option.Forwarding"); dojo.declare("iwc.widget.mail.option.Forwarding", iwc.widget.mail.option.Forwarding, { postCreate: function () { this.inherited(arguments); this.keepCopy.setDisabled(true); }, /*validateInput: function () { var valid = false; if (valid = this.inherited(arguments) ) { // break up the addresses first // use delimiter ";, " var a = this.addresses.value.split(/[;, ]+/); dojo.forEach(a, function(b) { if (b && b.indexOf("@yourcompany.com") == -1) valid = false; }); // i18n your error string if (!valid) this.forwarderror.show("Forward address must be employess of yourcompany.com"); } return valid; },*/ toggleForward: function() { var enabled = this.enabled.checked; this.addresses.attr('disabled',!enabled); /*if(enabled) { dojo.removeClass(this.addresses, "disabled"); } else { dojo.addClass(this.addresses, "disabled"); }*/ if(!enabled) { this.enabled.setDisabled(true); dojo.removeClass(this.addresses, "disabled"); } else { dojo.addClass(this.addresses, "disabled"); } }, last: "" } );