[haiku-development] Re: Additional Functionality to BMessenger

  • From: Rene Gollent <anevilyak@xxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Thu, 30 May 2019 08:01:51 -0400

On Thu, May 30, 2019 at 7:54 AM Hamish Morrison <hamishm53@xxxxxxxxx> wrote:

Ah I see. It would be nice if a BLooper could listen to and dispatch
multiple sources of events though - i.e. not only BMessages from a
port, but also readiness notifications on sockets. Other platforms'
runloops provide this and it's quite a clean model, since you can keep
everything on one thread.

wait_for_objects() (c.f. OS.h) can technically do that, but not within
the looper model; ergo, you'd have to manually handle subsequently
retrieving the message from the port and forward it on to an actual
looper for message processing, if you wanted to go that route.

Regards,

Rene

Other related posts: