Esempio n. 1
0
        /// <summary>
        /// If the OofSettings have been changed call SetUserOofSettings to
        /// update them.
        /// </summary>
        /// <param name="sender">The parameter is not used.</param>
        /// <param name="e">The parameter is not used.</param>
        private void OkButton_Click(object sender, EventArgs e)
        {
            try
            {
                this.Cursor = Cursors.WaitCursor;

                // If there's no OofSettings loaded then do nothing
                if (this.originalOofSettings == null)
                {
                    return;
                }

                // If the current and original OofSettings are the same do nothing
                if (ComparisonHelper.IsEqual(this.originalOofSettings, this.GetFormOofSettings()))
                {
                    return;
                }

                this.CurrentService.SetUserOofSettings(this.TargetMailbox.Address, this.GetFormOofSettings());
            }
            finally
            {
                this.Cursor = Cursors.Default;
            }
        }