コード例 #1
0
 /// <summary>
 ///     Returns flase if user cancels the operation.
 /// </summary>
 /// <param name="owner"></param>
 /// <param name="processIDs">IDs of processes to check</param>
 /// <param name="processChildren">Check child processes as well</param>
 /// <returns></returns>
 public static bool ShowDialog(Form owner, int[] processIDs, bool processChildren)
 {
     using (var pw = new ProcessWaiter())
     {
         pw.Icon = owner.Icon;
         pw.processWaiterControl1.Initialize(processIDs, processChildren);
         return(pw.ShowDialog(owner) == DialogResult.OK);
     }
 }
コード例 #2
0
 public static Task <bool?> CheckForProcessesBlockingDir(string fullDirectory)
 {
     return(ProcessWaiter.CheckForRunningProcesses(new[] { fullDirectory }, new string[0]));
 }
コード例 #3
0
 public static Task <bool?> CheckForProcessesBlockingKoiDir()
 {
     return(ProcessWaiter.CheckForRunningProcesses(new[] { InstallDirectoryHelper.GameDirectory.FullName }, new[] { @"^Koikatsu HF Patch v[\d\.]+$", "^KKManager$", "^StandaloneUpdater$" }));
 }