I am working on pydfb support right now and in testing decided to remove my pygame installation. :) This is an easy way to come accross any unneccessary pygame imports.


In src/eveny.py we do "import pygame.locals as key" and setup DEFAULT_KEYMAP as a dictionary keyed by lots of key.* members. Inside freevo_config.py we do KEYMAP = DEFAULT_KEYMAP and access this elsewhere as config.KEYMAP.

I would like to remove the pygame reference from src/event.py and therefore rearrange where DEFAULT_KEYMAP and KEYMAP are defined. In rc.py there is a class for attaching keyboard callbacks but I don't think that is a good spot for it either. The only other pygame code is in src/gui/ but that is for display right? Well, the keyboard callback for pygame is actually attached there.

I don't really know what should be done here. Dischi, perhaps you already have plans for this?

Some ramblings / ideas (none of which I'm set on, just throwing things out):

-Make a src/input/ directory and abstract the input sources there, similar to how src/gui/displays abstracts the display.

-Make all input come from plugins: input_pygame, input_lirc, input_evdev, input_mouse (lol), input_pydfb, input_kb (direct kb interface without pygame perhaps).

-just move the pygame input into the sdl display module, if you're not using pygame then input will come from a plugin (evdev, lirc, etc), ie: still use other plugins for input.

Any other ideas?

-Rob


------------------------------------------------------- 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=5047&alloc_id=10808&op=click _______________________________________________ Freevo-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/freevo-devel

Reply via email to