When making apps in lazarus, whenever I use sleep, it does weird things. For example, I can't close the screen while its sleeping, I can't resize it, no Onclick events can be called, everything freezes for however long it's sleeping. Is there an alternative to sleep that will still keep everything functional?
Thanks
Footy
E: Found this suggestion online. The only downside is when I am moving a screen, everything stops, but atleast it's better then it was.
Code:Procedure FSleep(Time : Integer); var i:integer; begin for i := 0 to Time do begin sleep(1); Application.ProcessMessages; end; end;