Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#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 (1)

fix.patch (869 bytes) - added by karl.forner 4 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 4 years ago by vrobin

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

comment:2 Changed 4 years ago by karl.forner

  • Resolution set to fixed
  • Status changed from new to closed

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;

}

Changed 4 years ago by karl.forner

comment:3 Changed 4 years ago by karl.forner

The patch has to be applied in trunk/Padre/lib/Padre/Wx ...

comment:4 Changed 4 years ago by bricas

Applied as svn r10977.

Note: See TracTickets for help on using tickets.