Matthieu Weber wrote:
> Besides, if we have two apps running at the same time (e.g. mplayer for
> the music and the image viewer, or mplayer for video and the menu
> displaing inside mplayer), both app must have an eventhandler, but
> only one (the image viewer) has the focus.
We already have this. There is an event that the audio player
stops. When you use the image viewer with background music, the viewer
doesn't care about that event, the background player does.
Right now we have a focused app. This app gets the event. If it
doesn't need it, it will be passed to all plugins until someone does
use it.
> Main loop: waits on filehandlers with the "select" system call. Each
> plugin dealing with sockets/pipes registers a data handler to the
> main loop, and when data is available on one of those (e.g. select wakes
> up), the data handler of the plugin is called in order to process the
> data.
This is the basic idea, but ...
> This architecture also removes the "sleep" from the main loop, which was
> much discussed about some time ago.
... pygame doesn't give us anything to select. You can't get a
filehandler for the keyboard or when a redraw needs to be done. The
latest gui tests and checking about a main loop gives me one solution:
pygame sucks, replace it.
> This is a mystery for me: in what case should an event be passed to the
> parent of an app?
When you don't register to a specific event, it may be possible that
your parent may need it. Problem with registering: each directory
wants to get notified when the directory on disc changes. But only the
current displayed directory should get that event.
Dischi
--
He didn't look mad, but they never did.
-- (Terry Pratchett, Strata)
-------------------------------------------------------
This SF.Net email is sponsored by BEA Weblogic Workshop
FREE Java Enterprise J2EE developer tools!
Get your free copy of BEA WebLogic Workshop 8.1 today.
http://ads.osdn.com/?ad_id=4721&alloc_id=10040&op=click
_______________________________________________
Freevo-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-devel