Changeset 10931


Ignore:
Timestamp:
2005-11-24T12:04:49+13:00 (18 years ago)
Author:
jrm21
Message:

instead of making all 'collectionmacros' read from the collect.cfg file
in the Global package, support Packagename:macroname arguments.

File:
1 edited

Legend:

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

    r10636 r10931  
    15221522    macros_map::const_iterator done_macro=cinfo.collection_macros.end();
    15231523    while (this_macro != done_macro) {
    1524 
    1525       disp.setcollectionmacro("Global",           // package
    1526                   this_macro->first,          // macro name
     1524      text_t package = "Global";
     1525      text_t macroname = this_macro->first;
     1526      // if this macro name is AAA:bbb then extract the package name
     1527      text_t::const_iterator thischar, donechar;
     1528      thischar = macroname.begin();
     1529      donechar = macroname.end();
     1530      while (thischar < donechar) {
     1531        if (*thischar == ':') {
     1532          package = substr(macroname.begin(),thischar);
     1533          macroname = substr(thischar+1,donechar);
     1534          break;
     1535        }
     1536        ++thischar;
     1537      }
     1538
     1539      disp.setcollectionmacro(package,
     1540                  macroname,
    15271541                  this_macro->second.first,   // params
    15281542                  this_macro->second.second); // value
Note: See TracChangeset for help on using the changeset viewer.