Changeset 2460 in Sophya for trunk/SophyaPI/PIext


Ignore:
Timestamp:
Nov 22, 2003, 6:46:07 PM (22 years ago)
Author:
ansari
Message:

Adaptation aux modifs interface PPersist - Reza 22 Nov 2003

Location:
trunk/SophyaPI/PIext
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/SophyaPI/PIext/nobjmgr.cc

    r2402 r2460  
    855855
    856856int nread = 0;
    857 if ( (s.NbTags() < 1) || (num >= s.NbTags()) ) {
     857int nbtags = 0;
     858#ifdef SANS_EVOLPLANCK
     859nbtags = s.NbTags();
     860#else
     861nbtags = s.NbNameTags();
     862#endif
     863if ( (nbtags < 1) || (num >= nbtags) ) {
    858864  if (num >= 0) {
    859865    cerr << "NamedObjMgr::ReadObj(PInPersist, " << num << "  Error! NbTags ="
    860          << s.NbTags() << endl;
     866         << nbtags << endl;
    861867    return;
    862868  }
     
    886892}
    887893 
    888 if (num < 0) { n0 = 0; n1 = s.NbTags(); }
     894if (num < 0) { n0 = 0; n1 = nbtags; }
    889895else { n0 = num; n1 = num+1; }
    890896for(i=n0; i<n1; i++) {
     
    902908  } ENDTRY;
    903909#else
    904   s.GotoTagNum(i);
     910  s.GotoNameTagNum(i);
    905911  nom = s.GetTagName(i);
    906912  try {
     
    936942try {
    937943  ppin = new PInPersist(flnm);
    938   if (ppin->NbTags() < 1)  obj = ppin->ReadObject();
     944  if (ppin->NbNameTags() < 1)  obj = ppin->ReadObject();
    939945  else   obj = NULL;
    940946}
  • trunk/SophyaPI/PIext/pisiadw.cc

    r2380 r2460  
    261261if (!ok) { mPin = NULL;  dap->SetReady(); return; }
    262262
    263 if (mPin->NbTags() < 1) {
     263int nbtags = 0;
     264#ifdef SANS_EVOLPLANCK
     265nbtags = mPin->NbTags();
     266#else
     267nbtags = mPin->NbNameTags();
     268#endif
     269
     270if (nbtags < 1) {
    264271  delete mPin;   mPin = NULL;
    265272  string no="";
     
    286293#else
    287294string tn;
    288 for(i=0; i<mPin->NbTags(); i++) {
     295for(i=0; i<mPin->NbNameTags(); i++) {
    289296  tn = mPin->GetTagName(i);
    290297  objlist->AppendItem(tn.c_str(), 5000+i);
Note: See TracChangeset for help on using the changeset viewer.