#include once "window9.bi"

function IsMouseOver(ByVal wnd As HWND) As Integer Export
  Dim As RECT re
  Dim As Point pt
  GetWindowRect(wnd,@re)
  GetCursorPos(@pt)
  if pt.x<re.left   then return 0
  if pt.x>re.right  then return 0
  if pt.y<re.top    then return 0
  if pt.y>re.bottom then return 0
  Return 1
End Function
