Ignore:
Timestamp:
2005-07-06T15:27:45+12:00 (19 years ago)
Author:
kjdon
Message:

Jeffrey's new parsing modifications, committed approx 6 July, 15.16

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/perllib/plugins/PagedImgPlug.pm

    r10168 r10218  
    137137
    138138sub BEGIN {
    139     @ISA = ('XMLPlug');
     139    @PagedImgPlug::ISA = ('XMLPlug');
    140140}
    141141
     
    220220
    221221sub new {
    222     my ($class) = @_;
    223     my $plugin_name = shift (@_);
    224     $self = new XMLPlug ("PagedImgPlug", @_);
    225 
    226     my $option_list = $self->{'option_list'};
    227     push( @{$option_list}, $options );
    228 
    229     if (!parsargv::parse(\@_,
    230              q^noscaleup^, \$self->{'noscaleup'},
    231              q^converttotype/.*/^, \$self->{'converttotype'},
    232              q^minimumsize/[0-9]*/100^, \$self->{'minimumsize'},
    233 
    234              q^thumbnailsize/[0-9]*/100^, \$self->{'thumbnailsize'},
    235              q^thumbnailtype/.*/gif^, \$self->{'thumbnailtype'},
    236              q^screenviewsize/[0-9]*/0^, \$self->{'screenviewsize'},
    237              q^screenviewtype/.*/jpg^, \$self->{'screenviewtype'},
    238              q^thumbnail^, \$self->{'thumbnail'},
    239              q^screenview^, \$self->{'screenview'},
    240              q^headerpage^, \$self->{'headerpage'},
    241              'documenttype/^(paged|hierarchy)$/paged', \$self->{'doctype'},
    242              "allow_extra_options")) {
    243    
    244     print STDERR "\nPagedImgPlug uses an incorrect option.\n";
    245     print STDERR "Check your collect.cfg configuration file.\n";
    246     $self->print_txt_usage("");  # Use default resource bundle
    247     die "\n";
    248     }
     222    my ($class) = shift (@_);
     223    my ($pluginlist,$inputargs,$hashArgOptLists) = @_;
     224    push(@$pluginlist, $class);
     225
     226    if(defined $arguments){ push(@{$hashArgOptLists->{"ArgList"}},@{$arguments});}
     227    if(defined $options) { push(@{$hashArgOptLists->{"OptList"}},$options)};
     228
     229    my $self = (defined $hashArgOptLists)? new XMLPlug($pluginlist,$inputargs,$hashArgOptLists): new XMLPlug($pluginlist,$inputargs);
    249230
    250231    return bless $self, $class;
     
    768749    $self->{'num_pages'} = 0;
    769750    my $topsection = $doc_obj->get_top_section();
    770     if ($self->{'doctype'} eq 'paged') {
     751    if ($self->{'documenttype'} eq 'paged') {
    771752    # set the gsdlthistype metadata to Paged - this ensures this document will
    772753    # be treated as a Paged doc, even if Titles are not numeric
     
    806787    my $topsection = $doc_obj->get_top_section();
    807788
    808     if ($self->{'doctype'} eq 'paged') {
     789    if ($self->{'documenttype'} eq 'paged') {
    809790    # set the gsdlthistype metadata to Paged - this ensures this document will
    810791    # be treated as a Paged doc, even if Titles are not numeric
Note: See TracChangeset for help on using the changeset viewer.