The Perl and Raku Conference 2025: Greenville, South Carolina - June 27-29 Learn more

package X3DGtk2Bin;
use strict;
our $FieldDefinitions = [
new X3DFieldDefinition( inputOutput, 'whichChoice', new SFInt32(-1) ),
];
sub _whichChoice {
my ($this, $value) = @_;
}
sub _children {
my ( $this, $value ) = @_;
$this->getWidget->remove($_) foreach $this->getWidget->get_children;
$this->getWidget->add( $value->[ $this->whichChoice ]->getValue->getWidget )
if $this->whichChoice < $value->length
and $this->whichChoice != -1;
}
1;
__END__