Esempio n. 1
0
 private void DoUpdateAvailable(UpdateAvailabledEventArgs e)
 {
     DoCompleted();
     if (OnUpdateAvailable != null)
     {
         OnUpdateAvailable(this, e);
     }
 }
Esempio n. 2
0
        private void OnUpdateAvailable(object sender, UpdateAvailabledEventArgs e)
        {
            Application.Current.Dispatcher.BeginInvoke(DispatcherPriority.Background, (MethodInvokerNoArg) delegate()
            {
                ProgramSettings.Instance.AppUpdateAvailable = true;
                ProgramSettings.Instance.AppUpdateVersion   = e.Release.Number;
                ProgramSettings.Instance.Save();
                miNewVersionAvailable.Visibility = System.Windows.Visibility.Visible;

                Updater updater = new Updater();
                updater.Execute(e.Release);
            });
        }