private void CheckForUpdates(OnCheckForUpdates obj = null) { Task.Factory.StartNew((Action)(() => { try { GlobalResponse globalSettings = this._flexClient.GetGlobalSettings(); this._configurationService.GlobalResponse = globalSettings; if (globalSettings != null) { this._updater.Update(globalSettings.VersionInfo.WindowsClientUrl); } } catch (Exception ex) { this._loggerService.Log(LogType.Error, "Update failed: " + ex.Message, ex.StackTrace); } this._messenger.Send <OnUpdateFinished>(new OnUpdateFinished()); })); }
private void OnCheckForUpdates(OnCheckForUpdates obj = null) { DispatcherHelper.CheckBeginInvokeOnUI((Action)(() => this.CurrentViewModel = (IBaseViewModel)this._updateProgramViewModel)); }