private void InnerInstall() { if (executeQueues.Count > 0) { var executor = executeQueues.Dequeue(); string targetText = executor.Name; TreeNode targetNode = null; if (executor is PPDInstallExecutor) { executor.ProgressText = installing; targetNode = treeView1.Nodes[0]; } else if (executor is IPAFontInstallExecutor) { executor.ProgressText = downloading; targetNode = treeView1.Nodes[0]; } else if (executor is BMSTOPPDInstallExecutor) { executor.ProgressText = installing; targetNode = treeView1.Nodes[1]; } else if (executor is LAVFiltersInstallExecutor) { executor.ProgressText = downloading; targetNode = treeView1.Nodes[1]; } label7.Text = String.Format("{0} {1} {2}%", executor.ProgressText, executor.Name, executor.Progress); var node = GetNodeFromText(targetNode, targetText); if (node != null) { node.ImageKey = Progress; } executor.Progressed += executor_Progressed; executor.Finished += executor_Finished; thread = new Thread(new ThreadStart(executor.Execute)); thread.Start(); return; } IsInstallFinishsd = true; if (InstallFinished != null) { InstallFinished.Invoke(this, EventArgs.Empty); } }
private void OnInstallFinished(object sender, FlutterInstallFinishedEventArgs e) { InstallFinished?.Invoke(sender, e); }