[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] App stops responding when minimized



On Tue, Dec 30, 2003 at 11:06:13PM -0000, psymaster@caths.co.uk wrote:
> I tried creating a new event with id USEREVENT, and set a timer of 1000 ms.
> 
> I had problems with getting QUIT events to exit though. Anyway, the
> problem is still there, once the window is minimized it stops responding
> (most of the times) and I can't select anything from the taskbar either.
> 
> I had once coded a simple game in pygame and an image viewer, and I
> remember having the same problem, but I fixed it by running the game at a
> set number of fps (for the game)or using event.wait() (for the image
> viewer). I can't seem to be able to do the same here. Maybe it has to do
> with the fact that I load one image file (sometimes bigger than 500 KB)
> every second or so, which needs resizing and blitting as well? I don't
> know why pygame effectively crashes my taskbar though.
>

I think I've had pygame ignore input until you call pygame.flip ...

(and then had code in a try block end up skipping the flip, and having
the program become unresponsive)