Delphi: Detect start and end of window move -


I am using OnIdle-event for a few simple animations, and it works properly. Although the problem occurs when the user starts moving or resizing the window, then OnIdle-event firing stops until the move / re-size operation is complete.

I know when this happens, so that I can stop all the animation. But how can I find out the window movement?

I mghie Note: Use a timer for animation, and Activate it / deactivate with message handlers.

In your case, you would like to add the following message handlers:

  // WMEnterSizeMove was removed when the "running" or "size" window ended / ended the process (Var message: TMessage); Message WM_ENTERSIZEMOVE; Process WMExitSizeMove (var Message: TMessage); Message WM_EXITSIZEMOVE; Process TForm.WMEnterSizeMove (var msg: TMessage); Start Animation Timer. Enabled: = false; inherited from; End; Process TForm.WMExitSizeMove (var msg: TMessage); Start the animation timer. Enabled: = true; inherited from; End;  

Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -