Version check. #1006

This commit is contained in:
Alessandro Ranellucci 2013-04-27 20:55:43 +02:00
parent bc9ff47d3f
commit f5bda326b8
4 changed files with 57 additions and 1 deletions

View file

@ -180,6 +180,7 @@ sub _build_field {
} elsif ($opt->{type} eq 'bool') {
$field = Wx::CheckBox->new($self->parent, -1, "");
$field->SetValue($opt->{default});
$field->Disable if $opt->{readonly};
EVT_CHECKBOX($self->parent, $field, sub { $self->_on_change($opt_key, $field->GetValue); });
$self->_setters->{$opt_key} = sub { $field->SetValue($_[0]) };
$tooltip .= " (default: " . ($opt->{default} ? 'yes' : 'no') . ")" if defined($opt->{default});