Michiel> 1) What if the user decides to import Tkinter next? Tkinter Michiel> notices that PyOS_InputHook is already set, and does not Michiel> reset it to its own event loop. Hence, Tkinter's events are Michiel> not handled. Similarly, if a user imports Tkinter before my Michiel> extension module, I don't reset PyOS_InputHook, so Tkinter's Michiel> events are handled but not mine. If I were to reset Michiel> PyOS_InputHook to my extension module's event loop, then my Michiel> events get handled but not Tkinter's.
This sounds sort of like the situation that existed with sys.exitfunc before the creation of the atexit module. Can't we develop an API similar to that so that many different event-loop-wanting packages can play nice together? (Then again, maybe I'm just being too simpleminded.) Skip _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com