Changeset 748 for trunk/gsdl


Ignore:
Timestamp:
1999-10-31T11:22:26+13:00 (25 years ago)
Author:
sjboddie
Message:

added collection argument to browserclass output_section_group
functions -- moved table functions to formattools

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/src/recpt/browsetools.cpp

    r737 r748  
    2929/*
    3030   $Log$
     31   Revision 1.33  1999/10/30 22:22:26  sjboddie
     32   added collection argument to browserclass output_section_group
     33   functions -- moved table functions to formattools
     34
    3135   Revision 1.32  1999/10/24 07:22:37  sjboddie
    3236   added a FullTOC option
     
    154158#include "OIDtools.h"
    155159
    156 
    157 // simply checks to see if formatstring begins with a <td> tag
    158 static bool is_table_content (const text_t &formatstring) {
    159   text_t::const_iterator here = formatstring.begin();
    160   text_t::const_iterator end = formatstring.end();
    161  
    162   while (here != end) {
    163     if (*here != ' ') {
    164       if (*here == '<') {
    165     if ((*(here+1) == 't' || *(here+1) == 'T') &&
    166         (*(here+2) == 'd' || *(here+2) == 'D') &&
    167         (*(here+3) == '>' || *(here+3) == ' '))
    168       return true;
    169       } else return false;
    170     }
    171     here ++;
    172   }
    173   return false;
    174 }
    175 
    176 static bool is_table_content (const format_t *formatlistptr) {
    177 
    178   if (formatlistptr == NULL) return false;
    179  
    180   if (formatlistptr->command == comText)
    181     return is_table_content (formatlistptr->text);
    182    
    183   return false;
    184 }
    185160
    186161// output_controls displays the detach, expand/contract contents,
     
    285260  // output this section
    286261  bool use_table = is_table_content (formatlistptr);
    287   tabcount += bptr->output_section_group (section, args, tabcount, formatlistptr, use_table,
     262  tabcount += bptr->output_section_group (section, args, "", tabcount, formatlistptr, use_table,
    288263                      metadata, getParents, collectproto, disp, outconvert,
    289264                      textout, logout);
     
    533508   
    534509    use_table = is_table_content (formatlistptr);
    535     tabcount += bptr->output_section_group (*thisparent, args, tabcount, formatlistptr,
     510    tabcount += bptr->output_section_group (*thisparent, args, "", tabcount, formatlistptr,
    536511                        use_table, metadata, getParents, collectproto,
    537512                        disp, outconvert, textout, logout);
     
    631606  // display children
    632607  bool use_table = is_table_content (formatlistptr);
    633   bptr->output_section_group (response, args, tabcount, formatlistptr, use_table,
     608  bptr->output_section_group (response, args, "", tabcount, formatlistptr, use_table,
    634609                  metadata, getParents, collectproto, disp, outconvert,
    635610                  textout, logout);
Note: See TracChangeset for help on using the changeset viewer.