Changeset 9133


Ignore:
Timestamp:
2005-02-22T14:35:18+13:00 (19 years ago)
Author:
mdewsnip
Message:

Added the "-hlist_at_top" option from Hierarchy.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/perllib/classify/AutoHierarchy.pm

    r9130 r9133  
    6969    'desc' => "{AutoHierarchy.suppresslastlevel}",
    7070    'type' => "flag",
    71     'reqd' => "no" }
    72       ];
     71    'reqd' => "no" },
     72      { 'name' => "hlist_at_top",
     73    'desc' => "{Hierarchy.hlist_at_top}",
     74    'type' => "flag",
     75    'reqd' => "no" } ];
    7376
    7477my $options = { 'name'     => "AutoHierarchy",
     
    105108             q^allvalues^, \$allvalues,
    106109             q^suppresslastlevel^, \$suppresslastlevel,
     110             q^hlist_at_top^, \$hlist_at_top,
    107111             "allow_extra_options")) {
    108112   
     
    128132    $buttonname = $self->generate_title_from_metadata($metadata) unless ($buttonname);
    129133    $self->{'title'} = $buttonname;
    130 
    131     if ($firstvalueonly != 0) {
    132     $firstvalueonly = 1;
    133     }
    134134    $self->{'firstvalueonly'} = $firstvalueonly;
    135  
    136     if ($allvalues != 0) {
    137     $allvalues = 1;
    138     }
    139135    $self->{'allvalues'} = $allvalues;
    140 
    141     if ($suppresslastlevel != 0) {
    142     $suppresslastlevel = 1;
    143     }
    144136    $self->{'suppresslastlevel'} = $suppresslastlevel;
     137    $self->{'hlist_at_top'} = $hlist_at_top;
    145138
    146139    # sortname is handled a bit differently - kjdon
     
    344337
    345338    if ($self->{'path_hash'}) {
    346     $classification = $self->get_entry ($self->{'title'}, "VList", "Invisible");
     339    if ($self->{'hlist_at_top'}) {
     340        $classification = $self->get_entry ($self->{'title'}, "HList", "Invisible");
     341    }
     342    else {
     343        $classification = $self->get_entry ($self->{'title'}, "VList", "Invisible");
     344    }
    347345    }
    348346
Note: See TracChangeset for help on using the changeset viewer.