Ejemplo n.º 1
0
        void UpdateChecker_NoUpdateAvailable(object sender, UpdateCheckEventArgs e)
        {
            try
            {
                if (InvokeRequired)
                {
                    Invoke(new Action(() => { UpdateChecker_NoUpdateAvailable(sender, e); }));
                    return;
                }

                MessageBox.Show(this, string.Format(Res.SettingsUpdateNotAvailable, e.ExeVersion.ToAppFormat()),
                                Res.SettingsUpdateCaption, MessageBoxButtons.OK, MessageBoxIcon.Information);
                UpdateCheckerFinished();
            }
            catch (Exception ex)
            {
                this.ShowError(ex);
            }
        }
Ejemplo n.º 2
0
        void UpdateChecker_UpdateCheckFailed(object sender, UpdateCheckEventArgs e)
        {
            try
            {
                if (InvokeRequired)
                {
                    Invoke(new Action(() => { UpdateChecker_UpdateCheckFailed(sender, e); }));
                    return;
                }

                MessageBox.Show(this, Res.SettingsUpdateFailed, Res.SettingsUpdateCaption,
                                MessageBoxButtons.OK, MessageBoxIcon.Error);
                UpdateCheckerFinished();
            }
            catch (Exception ex)
            {
                this.ShowError(ex);
            }
        }
Ejemplo n.º 3
0
        void UpdateChecker_UpdateAvailable(object sender, UpdateCheckEventArgs e)
        {
            try
            {
                if (InvokeRequired)
                {
                    Invoke(new Action(() => { UpdateChecker_UpdateAvailable(sender, e); }));
                    return;
                }

                if (MessageBox.Show(this, string.Format(Res.SettingsUpdateAvailable, e.WebVersion.ToAppFormat()),
                                    Res.SettingsUpdateCaption, MessageBoxButtons.YesNo, MessageBoxIcon.Question)
                    == DialogResult.Yes)
                {
                    e.OpenUpdateUrl();
                }

                UpdateCheckerFinished();
            }
            catch (Exception ex)
            {
                this.ShowError(ex);
            }
        }