Hi, I have a fairly large (>5K loc) Perl program that has a Windows UI. I've been applying Perl::Critic recommendations to it, but packaging the code breaks the UI (the buttons quit working and the scrollbar disappears). Here's a sample:
sub DBWindow_Show { ... # build window $DBWindow = Win32::GUI::Window->new( -name => 'DBWindow', -text => 'ldms_core database setup', -class => $ldms_core_class, -dialogui => 1, ); ... # Begin button row $btn_DBWindowDefault = $DBWindow->AddButton( -name => 'DBWindowDefault', -text => 'Ok', -tabstop => 1, -default => 1, # Give button darker border -ok => 1, # press 'Return' to click this button -pos => [ 25, $nexthoriz += 25 ], -size => [ 60, 20 ], ); ... $DBWindowsb = $DBWindow->AddStatusBar(); ... # Resize, position and display $DBWindow->Resize( $w, $h ); $DBWindow->Move( $wx, $wy ); $DBWindow->Show(); return 0; } ... # What to do when the button is clicked ####################################### sub DBWindowDefault_Click { ... return 0; } I'm just adding "package ldms_core;" at the top and "1;__END__" at the bottom. Any ideas? thanks, -- "I spent all me tin with the ladies drinking gin, So across the Western ocean I must wander" -- traditional ------------------------------------------------------------------------------ Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB _______________________________________________ Perl-Win32-GUI-Users mailing list Perl-Win32-GUI-Users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-users http://perl-win32-gui.sourceforge.net/