Ticket #835 (closed defect: fixed)
Function list not populated on initial panel showing
| Reported by: | bricas | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | |
| Component: | editor | Version: | trunk |
| Keywords: | Cc: |
Description
Steps to replicate:
1) Load Padre
2) Make sure the "functions" panel is not visible.
3) Load a perl document (for example lib/Padre.pm)
4) Make the "fuctions" panel visible.
Result: empty function list, even though it has functions defined.
Attachments
Change History
comment:2 Changed 3 years ago by karl.forner
- Status changed from new to closed
- Resolution set to fixed
I guess I found a fix. The bug is in my opinion due to incorrect call of Padre::Wx::Main->refresh_functions without argument when called by the lock() system.
Added a default argument of $self->current, and it seems to work. Here's the method:
sub refresh_functions {
my $self = shift;
return unless $self->has_functions;
return if $self->locked('REFRESH');
return unless $self->menu->view->{functions}->IsChecked?;
my @windows = @_;
push @windows, $self->current unless @windows;
$self->functions->refresh(@windows);
return;
}

Problem reproduced (for what it's usefull :) )