Re: GTK2::Button retrieved from Tie::IxHash hash value does not render
- From: Emmanuel Rodriguez <emmanuel rodriguez gmail com>
- To: Roderich Schupp <roderich schupp googlemail com>
- Cc: gtk-perl-list gnome org
- Subject: Re: GTK2::Button retrieved from Tie::IxHash hash value does not render
- Date: Fri, 22 Jul 2011 10:03:42 +0200
On Fri, Jul 22, 2011 at 08:45, Roderich Schupp
<roderich schupp googlemail com> wrote:
On Thu, Jul 21, 2011 at 7:29 PM, Emmanuel Rodriguez
<emmanuel rodriguez gmail com> wrote:
It seems that Tie::IxHash is storing the string representation of the
buttons instead of the real values.
No. Otherwise
Â$button{qbimport}->signal_connect( clicked => \&qbimport );
would already have died. And your "workaround" wouldn't work either.
Right :)
I didn't had the chance to try the code that I posted earlier.
I played with your sample now and it seems that the culprit is then:
$vbox->add($button{$_}) for (keys %button);
There's something odd going on there with the reference to the button.
This code works, so $_ is a valid object (no runtime error).
$_->show() for (values %button);
This works too:
my $copy;
$vbox->add($copy = $_) for (values %button);
This fails as described in the original emails:
$vbox->add($_) for (values %button);
--
Emmanuel Rodriguez
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]