use strict;
- use vars qw($VERSION @ISA @EXPORT);
+ use vars qw($VERSION @ISA);
$VERSION = '0.01';
- require Exporter;
require DynaLoader;
- @ISA = qw(Exporter DynaLoader);
- @EXPORT = qw(NewRect RectX RectY RectW RectH);
+ @ISA = qw(DynaLoader);
+
#################### subroutine header end ####################
+sub new
+{
+ my $self = shift;
+ my ($x, $y, $w, $h) = @_;
+ $self = \SDL::Rect::NewRect($x, $y, $w, $h);
+ return $self;
+}
#################### main pod documentation begin ###################
## Below is the stub of documentation for your module.
#################### main pod documentation end ###################
-bootstrap SDL::Rect $VERSION;
-
+bootstrap SDL::Rect;
1;
# The preceding line will help the module return a true value
# -*- perl -*-
# t/001_load.t - check module loading and create testing directory
+no AutoLoader;
use Test::More tests => 2;
BEGIN { use_ok( 'SDL::Rect' ); }
-my $object = SDL::Rect::NewRect(0,0,0,0);
+my $object = SDL::Rect->new(0,0,0,0);
isa_ok ($object, 'SDL::Rect');