fire event after mouse moves form – FMX C++

  

I want to run a block of code after my form has been moved on the screen by the traditional “left-mouse down on caption bar and drag to new spot”. OnMouseUp only works on the form itself, not for mouse click on the title bar.

This is C++ and Win32 app.

thanks,
russ

UPDATE 1: Showing code i implemented based on Remy’s answer. I implemented his code from that other post and then added another item to the switch(uMsg) to catch the WM_MOVE message. This didn’t work.

case WM_MOVE:
{
ShowMessage(“Moved”);
}

UPDATE 2: I changed the above from WM_MOVE to WM_EXITSIZEMOVE based on Remy’s comment and it works great now. Fires 1 time when i get through moving the form.

case WM_EXITSIZEMOVE:
{
ShowMessage(“Moved”);
}

Just what i wanted.

Comments are closed.