Re: [Orbit-python-list] Orbit-python and threading?
Status: Inactive
Brought to you by:
tack
From: Christian R. R. <ki...@as...> - 2001-11-07 20:41:44
|
On Wed, 7 Nov 2001, Marijn Vriens wrote: > I am trying to get some program to work with python-orbit. Because I > need it to do some more work besides just waiting for corba requests > to come in, and i didn't see any "idle" hooks (ala gtk.py), My > solution is to dump the Orbit run() in it's own thread, while the > rest of the processing goes on in the mainthread. I've attached a patch to o-p from cvs that does the threading changes. You'll need pygtk compiled without threads (or from CVS with PYGTK_NO_THREADS env var set). You should initialize the orb using something like: orb = CORBA.ORB_init( [], CORBA.ORB_ID, CORBA.TRUE ) (the third parameter says you want to use the gtk mainloop. Then just substitute the orb.run() call for gtk.mainloop(). It should work. Take care, -- Christian Reis, Senior Engineer, Async Open Source, Brazil. http://async.com.br/~kiko/ | [+55 16] 272 3330 | NMFL |