AcTools.Utils.Helpers.ProcessExtension.GetWindowsHandles C# (CSharp) Метод

GetWindowsHandles() публичный статический Метод

public static GetWindowsHandles ( this process ) : IReadOnlyList
process this
Результат IReadOnlyList
        public static IReadOnlyList<IntPtr> GetWindowsHandles(this Process process) {
            var handles = new List<IntPtr>();
            foreach (ProcessThread thread in Process.GetProcessById(process.Id).Threads) {
                User32.EnumThreadWindows(thread.Id, (hWnd, lParam) => { handles.Add(hWnd); return true; }, IntPtr.Zero);
            }
            return handles;
        }
    }