Changeset 2762 in Sophya for trunk/SophyaPI/PIext/nobjmgr.cc
- Timestamp:
- May 24, 2005, 6:31:58 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SophyaPI/PIext/nobjmgr.cc
r2757 r2762 499 499 list<string>::iterator ii; 500 500 for(ii=odel.begin(); ii != odel.end(); ii++) DelObj_P(*ii,true); 501 if (myImgApp) { 502 if ( !_fgimgapp ) myImgApp->LockMutex(); 503 (myImgApp->ObjMgrW())->UpdateList(did); 504 if ( !_fgimgapp ) myImgApp->UnlockMutex(true); 505 } 501 502 UpdateObjMgrWindow_P(did); // On met a jour la fenetre de gestion des objets 506 503 } 507 504 … … 1388 1385 else if (arr) wrsid = myImgApp->DispImage(arr, n1, dopt, false, 0, fglock); 1389 1386 1390 AddWRsId (nom, wrsid);1387 AddWRsId_P(nom, wrsid); 1391 1388 return; 1392 1389 } … … 1429 1426 wrsid = myImgApp->DispImage(arr, n1, dopt, fgimagnav, 0, fglock); 1430 1427 1431 AddWRsId (nom, wrsid);1428 AddWRsId_P(nom, wrsid); 1432 1429 return; 1433 1430 } … … 1476 1473 PISurfaceDrawer* sdr = new PISurfaceDrawer(arr, true, true, true); 1477 1474 wrsid = myImgApp->Disp3DDrawer(sdr, n1, dopt, "", 0, fglock); 1478 AddWRsId (nom, wrsid);1475 AddWRsId_P(nom, wrsid); 1479 1476 return; 1480 1477 } … … 1533 1530 } 1534 1531 1535 AddWRsId (nom, wrsid);1532 AddWRsId_P(nom, wrsid); 1536 1533 return; 1537 1534 } … … 1597 1594 } 1598 1595 1599 AddWRsId (nom, wrsid);1596 AddWRsId_P(nom, wrsid); 1600 1597 1601 1598 return; … … 1712 1709 void NamedObjMgr::AddWRsId(string & nom, int wrsid) 1713 1710 { 1711 ZSync zs(*myMutex); zs.NOp(); 1712 AddWRsId_P(nom, wrsid); 1713 } 1714 1715 /* --Methode-- */ 1716 void NamedObjMgr::AddWRsId_P(string & nom, int wrsid) 1717 { 1714 1718 if(wrsid != 0) { 1715 1719 NObjList::iterator it = myObjs->find(nom); … … 1724 1728 { 1725 1729 if (!myImgApp) return; 1726 //RZDEL ZSync zs(*myMutex); zs.NOp(); 1730 ZSync zs(*myMutex); zs.NOp(); 1731 UpdateObjMgrWindow_P(did); 1732 } 1733 1734 /* --Methode-- */ 1735 void NamedObjMgr::UpdateObjMgrWindow_P(int did) 1736 { 1737 if (!myImgApp) return; 1727 1738 if ( !_fgimgapp ) myImgApp->LockMutex(); 1739 if ( !(myImgApp->ObjMgrW())->Visible() || 1740 ( (myImgApp->ObjMgrW())->GetCurDirId() != did) ) { 1741 if ( !_fgimgapp ) myImgApp->UnlockMutex(true); 1742 return; 1743 } 1728 1744 1729 1745 (myImgApp->ObjMgrW())->ClearObjList(); … … 1738 1754 (myImgApp->ObjMgrW())->AddObj(cn.c_str(), (*it).second.oid); 1739 1755 } 1740 1741 1756 if ( !_fgimgapp ) myImgApp->UnlockMutex(true); 1757 return; 1742 1758 } 1743 1759
Note:
See TracChangeset
for help on using the changeset viewer.