The problem is that Tk's event loop and Event's event loop are mutually 
exclusive.  POE can use Event, via POE::Loop::Event, just as easily as it can 
use Tk's via POE::Loop::Tk.

POE::Component::Generic "hangs" in a separate process, so the main 
POE::Loop::Tk will continue on.

-- 
Rocco Caputo <rcap...@pobox.com>


On Aug 21, 2011, at 16:40, Gunnar Strand wrote:

> Yes, I was also thinking along those lines, but I was sort of hoping for
> possible way to marry the Tk and the Event loops. Since POE can utilize the
> Tk loop, perhaps Event could have been convinced too.
> 
> This is really only a one-way communication, so I was thinking about making
> this a PoCo::Generic session and let it "hang" in the Event::loop call.
> Would that work, or would POE hang too?
> 
> 
> 2011/8/21 Nick Perez <n...@nickandperla.net>
> 
>> It would probably make sense to run the RCU in a child and have it push
>> events over the pipes of POE::Wheel::Run. Not as monolithic that way,
>> but then you could generalize what kind of interface those two pieces
>> use to chat. At that point you could then replace the RCU part with
>> anything else that also understands the interface.
>> 
>> On Sun, 21 Aug 2011 16:55:13 +0200
>> Gunnar Strand <gurra.str...@gmail.com> wrote:
>> 
>>> I'm working on a simple media control system and I am using POE with
>>> Tk. I found the "RCU" (remote control unit) perl module hierachy to
>>> use with my infrared remote control. RCU can be event-controlled, but
>>> it is using the "Event" event loop. Preferably I'd like to have
>>> everything controlled by the same event loop and not having to poll
>>> the RCU periodically. Is this doable?
>>> 
>>> BR
>>> Gunnar
>> 
>> 
>> --
>> 
>> Nicholas Perez
>> XMPP/Email: n...@nickandperla.net
>> http://search.cpan.org/~nperez/
>> http://github.com/nperez
>> 

Reply via email to