private void MainWindow_OnActivated(object sender, EventArgs e) { if (FirstTimeActivated) { FirstTimeActivated = false; var allAssemblies = new List <LeagueSharpAssembly>(); foreach (var profile in Config.Instance.Profiles) { allAssemblies.AddRange(profile.InstalledAssemblies); } allAssemblies = allAssemblies.Distinct().ToList(); GitUpdater.ClearUnusedRepos(allAssemblies); PrepareAssemblies(allAssemblies, Config.Instance.FirstRun || Config.Instance.UpdateOnLoad, true, true); } var text = Clipboard.GetText(); if (text.StartsWith(LSUriScheme.FullName)) { Clipboard.SetText(""); LSUriScheme.HandleUrl(text, this); } }
private async void MainWindow_OnActivated(object sender, EventArgs e) { var text = Clipboard.GetText(); if (text.StartsWith(LSUriScheme.FullName)) { Clipboard.SetText(""); await LSUriScheme.HandleUrl(text, this); } }
private async void InstallFromDbItem_OnClick(object sender, RoutedEventArgs e) { if (this.AssembliesDBDataGrid.SelectedItems.Count == 0) { return; } var assemblies = this.AssembliesDBDataGrid.SelectedItems.Cast <Data.Assemblies.Assembly>().ToList(); foreach (var assembly in assemblies) { await LSUriScheme.HandleUrl(assembly.GithubUrl, this); } }
private async void MainWindow_OnActivated(object sender, EventArgs e) { try { var text = Clipboard.GetText(); if (text.StartsWith(LSUriScheme.FullName)) { Clipboard.SetText(string.Empty); await LSUriScheme.HandleUrl(text, this); } } catch (Exception ex) { Utility.Log(LogStatus.Error, ex.Message); } }
private void MainWindow_OnActivated(object sender, EventArgs e) { if (FirstTimeActivated) { FirstTimeActivated = false; PrepareAssemblies(Config.SelectedProfile.InstalledAssemblies, Config.FirstRun || Config.UpdateOnLoad, true); } var text = Clipboard.GetText(); if (text.StartsWith(LSUriScheme.FullName)) { Clipboard.SetText(""); LSUriScheme.HandleUrl(text, this); } }
private void MainWindow_OnActivated(object sender, EventArgs e) { if (FirstTimeActivated) { FirstTimeActivated = false; //Try to login with the saved credentials. if (!Auth.Login(Config.Instance.Username, Config.Instance.Password).Item1) { ShowLoginDialog(); } else { OnLogin(Config.Instance.Username); } var allAssemblies = new List <LeagueSharpAssembly>(); foreach (var profile in Config.Instance.Profiles) { allAssemblies.AddRange(profile.InstalledAssemblies); } allAssemblies = allAssemblies.Distinct().ToList(); GitUpdater.ClearUnusedRepos(allAssemblies); PrepareAssemblies(allAssemblies, Config.Instance.FirstRun || Config.Instance.UpdateOnLoad, true, true); Remoting.Init(); } var text = Clipboard.GetText(); if (text.StartsWith(LSUriScheme.FullName)) { Clipboard.SetText(""); LSUriScheme.HandleUrl(text, this); } }