package Tk::MyFrame; use Tk::Frame; @ISA = qw(Tk::Frame); Construct Tk::Widget 'MyFrame'; #公開したいサブルーチン #@EXPORT = qw(); use strict; #use base qw(Tk::Widget); sub Populate { my($cw, $args) = @_; $cw->SUPER::Populate($args); return; # my $b = $cw->Frame(); # $b->pack(-expand => 1, -fill => 'both'); # $cw->Advertise('MyFrame', => $b); # $cw->ConfigSpecs(DEFAULT => [$b]); # $cw->Delegates(DEFAULT => $b); } sub ClassInit { my ($class, $mw) = @_; return $class; } BEGIN { } sub new { my ($class, @args) = @_; my $self = Tk::Frame->new(@args); return bless $self, ref($class) || $class; } sub DESTROY { my $this = shift; $this->SUPER::DESTROY(@_); } 1;