代码改变世界

获取鼠标点窗口句柄

2007-08-02 11:44  ubunoon  阅读(391)  评论(0编辑  收藏  举报

/* The GetCursorPos function retrieves the cursor's position, in screen coordinates. */
      BOOL GetCursorPos(
                   LPPOINT &point
                    );

/* The WindowFromPoint function retrieves a handle to the window that contains the specified point. */
      HWND WindowFromPoint(
                           POINT point
                          );

/*The GetWindow function retrieves a handle to a window that has the specified relationship (Z-Order or owner) to the specified window. */
      HWND GetWindow(
                     HWND hWnd,
                     UINT    uCmd                    //通过把uCmd代码设置为GW_HWNDNEXT来获取兄弟窗口的句柄
                    );