Beispiel #1
0
        //刷新托盘区域:已中止进程的图标将会被系统删除。
        public static void Refresh()
        {
            int   hwnd = GetSysTrayWnd();
            HRect nr   = new HRect();

            Windows.GetClientRect((IntPtr)hwnd, out nr);

            for (int x = 0; x < nr.right; x = x + 2)
            {
                for (int y = 0; y < nr.bottom; y = y + 2)
                {
                    Message.SendMessage(hwnd, MsgId.WM_MOUSEMOVE, 0, Message.MakeLParam(x, y));
                }
            }
        }
Beispiel #2
0
 public static extern bool GetClientRect(IntPtr hWnd, out HRect lpRect);
Beispiel #3
0
 public static extern bool GetWindowRect(HandleRef hwnd, out HRect rect);