Exemple #1
0
        public WindowViewModel( WindowInfo window )
        {
            Window = window;

            Process process = window.GetProcess();
            ProcessName = process?.ProcessName ?? "Not Found!";
            CompanyName = process?.MainModule.FileVersionInfo.CompanyName ?? "";
            ClassName = window.GetClassName();
            Title = window.GetTitle();
            IsVisible = window.IsVisible();
        }
 public bool Equals( WindowInfo window )
 {
     return
         ClassName == window.GetClassName() &&
         ( Visible == WindowVisible.Both || ( window.IsVisible() && Visible == WindowVisible.True ) ) &&
         ( Title == null || window.GetTitle() == Title );
 }