title: how to detect when mouse leaves the window win32
body: <p>I am creating an application with the win32 api and I have a boolean <code>isLeftClickPressed</code> which is set to true when I receive a <code>WM_LBUTTONDOWN</code> message. when I receive a <code>WM_LBUTTONUP</code> message I set it to false. this works fine, however if I hold down the left mouse button and move my cursor out of the window and release my mouse, it never send a <code>WM_LBUTTONUP</code> message. I am not looking for a way to get around this rather just to find out when my mouse leaves the window and then set <code>isLeftClickPressed</code> to false.</p>
  <p>any help would be appreciated.</p>