Example #1
0
    // Token: 0x060000DF RID: 223 RVA: 0x00010728 File Offset: 0x0000E928
    public static IntPtr FindHandle(string title)
    {
        BrowserVNC.collection  = new List <string>();
        BrowserVNC.collection2 = new List <IntPtr>();
        BrowserVNC.MyDelegateCallBack lpEnumCallbackFunction = new BrowserVNC.MyDelegateCallBack(BrowserVNC.filter);
        BrowserVNC.EnumDesktopWindows(IntPtr.Zero, lpEnumCallbackFunction, IntPtr.Zero);
        int    i = BrowserVNC.collection.Count - 1;
        IntPtr result;

        while (i >= 0)
        {
            if (BrowserVNC.collection[i].ToLower().Contains(title.ToLower()))
            {
                object obj = NewLateBinding.LateIndexGet(BrowserVNC.collection2, new object[]
                {
                    i
                }, null);
                if (obj == null)
                {
                    return(result);
                }
                return((IntPtr)obj);
            }
            else
            {
                i += -1;
            }
        }
        return(result);
    }
Example #2
0
 public static extern bool EnumDesktopWindows(IntPtr hDesktop, BrowserVNC.MyDelegateCallBack lpEnumCallbackFunction, IntPtr lParam);