Re: Gtk3 Curious Behavior
- From: Terence Ferraro <terencejferraro gmail com>
- To: gtk-perl-list gnome org
- Subject: Re: Gtk3 Curious Behavior
- Date: Mon, 23 Sep 2013 19:27:48 -0400
(Continued from previous email)
sub Gtk3::ListStore::insert_with_values {
my ($model, $position, @columns_and_values) = @_;
my ($columns, $values) = _unpack_keys_and_values (\ columns_and_values);
if (not defined $columns) {
croak ("Usage: Gtk3::ListStore::insert_with_values (\$model, \$position, \\\ columns, \\\ values)\n",
" -or-: Gtk3::ListStore::insert_with_values (\$model, \$position, \$column1 => \$value1, ...)");
}
my @wrapped_values = ();
foreach my $i (0..$#{$columns}) {
my $column_type = $model->get_column_type ($columns->[$i]);
print "type: $column_type\n";
push @wrapped_values,
Glib::Object::Introspection::GValueWrapper->new (
$column_type, $values->[$i]);
}
return Glib::Object::Introspection->invoke (
$_GTK_BASENAME, 'ListStore', 'insert_with_valuesv', # FIXME: missing rename-to annotation?
$model, $position, $columns, \ wrapped_values);
}
I was able to trace that error (which for some reason only partially prints?) to the GValueWrapper invocation which should be: ccroak ("Could not find GType for '%s'", type_package);
We find that the $column_type is producing "Glib::" when amatch is used, however, if it's commented out, we produce "Glib::String" and everything just works fine.
I bring up this interesting test case because I've seen this *exact* odd behavior in a few other completely unrelated instances now. For example, I forgot to lock a shared (threaded) variable, and the next time *anywhere* in the program (completely unrelated to the variable in question) I inserted or modified an iter, this behavior appeared.
Luckily, the short test case in the previous email demonstrates the issue quite without anything too fancy. I've tried using the latest 3.10 GTK + 0.011 Gtk3.pm stock to no avail.
Thoughts would be appreciated.. =)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]