Re: per thread x connection
- From: Ulrich Czekalla <ulrich czekalla utoronto ca>
- To: Havoc Pennington <hp redhat com>
- Cc: gtk-devel-list gnome org
- Subject: Re: per thread x connection
- Date: Thu, 26 Apr 2001 09:29:02 -0400
We need an x connection per display in order to facilitate the implementation
of sendmessage across processes. Basically we need an event/signal loop for each
thread. This simplifies things, allowing individual threads to wait on their
X connection for new events.
In addition to a per-thread connection, Wine would need to be in charge of
waiting for events when idling. So we need some way of polling on behalf of
gtk.
The more I think about it, it seems like it will be a lot of work.
/Ulrich
Havoc Pennington wrote:
>
> Ulrich Czekalla <ulrich czekalla utoronto ca> writes:
> >
> > I'm currently looking into the creation of a gtk based user dll for
> > the Wine project. One of the requirements will be to have a per thread
> > X connection.
> >
> > I have been looking at the source and noticed that the X connection
> > is created during gdk initialization and is put into a global variable.
> >
> > How difficult would it be to modify the code to allow for a per thread
> > X connection? Are there any fundamental assumptions for one global
> > X connection?
> >
>
> Yes. Basically every global variable in GTK assumes this. Or nearly
> every one.
>
> Erwann is working on multiple display support, which will allow
> connections to more than one X display. But you're still looking at
> the fairly limited thread-safety model of GTK itself.
>
> Without knowing more details on why you have this per-thread X
> connection requirement, it's hard to tell you what would be required
> to meet it. What are you trying to achieve? Multiple display support?
>
> Havoc
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]