… | |
… | |
485 | |
485 | |
486 | my %want_ext; |
486 | my %want_ext; |
487 | |
487 | |
488 | for (map { split /,/, $TERM->resource ("perl_ext_$_") } 1, 2) { |
488 | for (map { split /,/, $TERM->resource ("perl_ext_$_") } 1, 2) { |
489 | if ($_ eq "default") { |
489 | if ($_ eq "default") { |
490 | $want_ext{$_}++ for qw(selection); |
490 | $want_ext{$_}++ for qw(selection option-popup); |
491 | } elsif (/-(.*)/) { |
491 | } elsif (/^-(.*)$/) { |
492 | delete $want_ext{$1}; |
492 | delete $want_ext{$1}; |
493 | } else { |
493 | } else { |
494 | $want_ext{$_}++; |
494 | $want_ext{$_}++; |
495 | } |
495 | } |
496 | } |
496 | } |
… | |
… | |
1043 | |
1043 | |
1044 | my $item; $item = { |
1044 | my $item; $item = { |
1045 | type => "button", |
1045 | type => "button", |
1046 | text => " $text", |
1046 | text => " $text", |
1047 | value => $value, |
1047 | value => $value, |
1048 | render => sub { ($item->{value} ? "✔" : " ") . $text }, |
1048 | render => sub { ($item->{value} ? "* " : " ") . $text }, |
1049 | activate => sub { $cb->($item->{value} = !$item->{value}); }, |
1049 | activate => sub { $cb->($item->{value} = !$item->{value}); }, |
1050 | }; |
1050 | }; |
1051 | |
1051 | |
1052 | $self->add_item ($item); |
1052 | $self->add_item ($item); |
1053 | } |
1053 | } |