Changeset 669 for trunk/gsdl/src/recpt/documentaction.cpp
- Timestamp:
- 1999-10-15T12:00:53+13:00 (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/gsdl/src/recpt/documentaction.cpp
r649 r669 28 28 /* 29 29 $Log$ 30 Revision 1.27 1999/10/14 23:00:53 sjboddie 31 finished changes to browsing support 32 30 33 Revision 1.26 1999/10/10 08:14:06 sjboddie 31 34 - metadata now returns mp rather than array … … 438 441 ((*format_here).second == "true")) 439 442 formatinfo.DocumentImages = true; 443 else if (((*format_here).first == "DocumentTitles") && 444 ((*format_here).second == "false")) 445 formatinfo.DocumentTitles = false; 440 446 else if ((*format_here).first == "DocumentHeading") 441 447 formatinfo.DocumentHeading = (*format_here).second; 442 else if (((*format_here).first == "Document ArrowsTop") &&448 else if (((*format_here).first == "DocumentContents") && 443 449 ((*format_here).second == "false")) 444 formatinfo.Document ArrowsTop= false;450 formatinfo.DocumentContents = false; 445 451 else if (((*format_here).first == "DocumentArrowsBottom") && 446 452 ((*format_here).second == "false")) 447 453 formatinfo.DocumentArrowsBottom = false; 448 else if (((*format_here).first == "DocumentGoTo") &&449 ((*format_here).second == "false"))450 formatinfo.DocumentGoTo = false;451 454 else if ((*format_here).first == "DocumentButtons") 452 455 splitchar ((*format_here).second.begin(), (*format_here).second.end(), … … 461 464 462 465 // never want arrows when text is expanded 463 if (gt) {466 if (gt) 464 467 formatinfo.DocumentArrowsBottom = false; 465 formatinfo.DocumentArrowsTop = false;466 }467 468 } 468 469 … … 555 556 disp.setmacro ("header", "document", "_textheader_"); 556 557 557 text_t pagetitle = response.docInfo[0].metadata["Title"].values[0]; 558 text_tarray pagetitlearray; 559 if (!response.docInfo[0].metadata["Title"].values[0].empty()) 560 pagetitlearray.push_back (response.docInfo[0].metadata["Title"].values[0]); 558 561 if (!gt) { 559 MetadataInfo_t *parent = response.docInfo[0].metadata["Title"].parent; 560 while (parent != NULL) { 561 pagetitle += ": " + parent->values[0]; 562 parent = parent->parent; 562 MetadataInfo_t *parenttitle = response.docInfo[0].metadata["Title"].parent; 563 while (parenttitle != NULL) { 564 if (!parenttitle->values[0].empty()) 565 pagetitlearray.push_back (parenttitle->values[0]); 566 parenttitle = parenttitle->parent; 563 567 } 564 568 } 569 reverse (pagetitlearray.begin(), pagetitlearray.end()); 570 text_t pagetitle; 571 joinchar (pagetitlearray, ": ", pagetitle); 565 572 disp.setmacro ("pagetitle", "document", pagetitle); 566 disp.setmacro ("thisOID", "Global", response.docInfo[0].metadata["archivedir"].values[0]); 573 574 if (is_top (arg_d)) 575 disp.setmacro ("thisOID", "Global", response.docInfo[0].metadata["archivedir"].values[0]); 576 else { 577 MetadataInfo_t *parentad = response.docInfo[0].metadata["archivedir"].parent; 578 text_t thisOID; 579 while (parentad != NULL) { 580 thisOID = parentad->values[0]; 581 parentad = parentad->parent; 582 } 583 disp.setmacro ("thisOID", "Global", thisOID); 584 } 567 585 568 586 if (args["u"] != "1") … … 712 730 } 713 731 714 int metasize = metadata.size();715 716 732 if (get_info (OID, collection, metadata, getParents, collectproto, inforesponse, logout)) { 717 733 int hastxt = inforesponse.docInfo[0].metadata["hastxt"].values[0].getint(); 718 734 int haschildren = inforesponse.docInfo[0].metadata["haschildren"].values[0].getint(); 719 735 720 736 if (arg_gt == 0) { 721 737 output_text (inforesponse.docInfo[0], formatlistptr, queryresponse.termInfo,
Note:
See TracChangeset
for help on using the changeset viewer.