Re: Possible bug with multiple copies of a window in multiple threads.



On Fri, 2004-01-09 at 06:44, Student wrote:
I originally put (a slightly less refined version of) this on the
sourceforge page, but I'm not sure that it gets looked at.  Sorry for
the duplication.


When the program given below (demo.pl) is run is should pop up two
windows with a label in each.  However I get the following error
messages:

variable is not of type Gtk2::Container at ./demo.pl line 40.
variable is not of type Gtk2::Widget at ./demo.pl line 41.

Can someone enlighten me on what is going wrong.

Thank you.

basically you're running into several issues. some of with are the app's
fault and others which aren't (from what i can tell) as a rule (at this
point) if you use threads you have to spawn them before ANY Gtk2-Perl
variables have been created. the reasons for this are rather complex and
the solutions even more so. really perl doesn't give us the tools to
allow it to be handled 'the right way'. and anything we eventually come
up with will be somewhat of a hack.

other than that i can't get it to work either. i'm getting the same
errors as you when i try to use multiple threads and sockets/plugs. you
might want to try separate processes, using fork. but otherwise i'm out
of ideas. i'll try and look into it and determine if it's the bindings
fault.

-rm




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]