private bool RunUpdateChecker() { this.Log.Info("Launching UpdateChecker"); var uc = new UpdateChecker(); uc.ShowDialog(); this.Log.Info("UpdateChecker Done."); return uc.IsClosingDown; }
private bool RunUpdateChecker() { this.Log.Info("Launching UpdateChecker"); var uc = new UpdateChecker(); //PlayDispatcher.Instance.UIDispacher = uc.Dispatcher; uc.ShowDialog(); this.Log.Info("UpdateChecker Done."); return uc.IsClosingDown; }
protected override void OnStartup(StartupEventArgs e) { base.OnStartup(e); #if(!DEBUG) AppDomain.CurrentDomain.UnhandledException += CurrentDomainUnhandledException; #else AppDomain.CurrentDomain.FirstChanceException += this.CurrentDomainFirstChanceException; #endif //Program.GamesRepository = new GamesRepository(); if (Program.GamesRepository.MissingFiles.Any()) { var sb = new StringBuilder( "Octgn cannot find the following files. The corresponding games have been disabled.\n\n"); foreach (string file in Program.GamesRepository.MissingFiles) sb.Append(file).Append("\n\n"); sb.Append("You should restore those files, or re-install the corresponding games."); ShutdownMode oldShutdown = ShutdownMode; ShutdownMode = ShutdownMode.OnExplicitShutdown; new Windows.MessageWindow(sb.ToString()).ShowDialog(); ShutdownMode = oldShutdown; } var uc = new UpdateChecker(); uc.ShowDialog(); if (!uc.IsClosingDown) { Program.MainWindowNew.Show(); } else { Program.MainWindowNew.Close(); Current.MainWindow = null; Program.Exit(); } if (e.Args.Any()) { Properties["ArbitraryArgName"] = e.Args[0]; } }
/// <summary> /// Runs update checker /// </summary> /// <returns>True if there is an update, else false</returns> internal static bool RunUpdateChecker() { Log.Info("Launching UpdateChecker"); var uc = new UpdateChecker(); uc.ShowDialog(); Log.Info("UpdateChecker Done."); return uc.IsClosingDown; }