Merge branch 'master' into pre/medCompatibility

This commit is contained in:
Paul RASCLE 2018-10-11 14:38:48 +02:00
commit 286eab9f3e
6 changed files with 19 additions and 11 deletions

View File

@ -99,7 +99,11 @@ namespace MED
#else #else
cosnt char* path = xmlPath.c_str(); cosnt char* path = xmlPath.c_str();
#endif #endif
return (GetFileAttributes(path) != INVALID_FILE_ATTRIBUTES); bool res = (GetFileAttributes(path) != INVALID_FILE_ATTRIBUTES);
#ifdef UNICODE
delete path;
#endif
return res;
#else #else
return (access(fileName.c_str(), F_OK) == 0); return (access(fileName.c_str(), F_OK) == 0);
#endif #endif

View File

@ -2431,8 +2431,9 @@ bool SMESH_Mesh::SortByMeshOrder(std::vector<SMESH_subMesh*>& theListToSort) con
{ {
TPosInList smPos = find( smBeg, smEnd, smVec[i] ); TPosInList smPos = find( smBeg, smEnd, smVec[i] );
if ( smPos != smEnd ) { if ( smPos != smEnd ) {
onlyOrderedList.push_back( smVec[i] );
sortedPos[ distance( smBeg, smPos )] = smPos; sortedPos[ distance( smBeg, smPos )] = smPos;
if ( sortedPos.size() > onlyOrderedList.size() )
onlyOrderedList.push_back( smVec[i] );
} }
} }
} }

View File

@ -534,6 +534,9 @@ namespace SMESH
char* path = baPath.data(); char* path = baPath.data();
#endif #endif
LibHandle libHandle = LoadLib( path ); LibHandle libHandle = LoadLib( path );
#if defined(WIN32) && defined(UNICODE)
delete path;
#endif
if (!libHandle) { if (!libHandle) {
// report any error, if occurred // report any error, if occurred
{ {

View File

@ -2656,6 +2656,11 @@ SMDS_Mesh* SMESH_MeshAlgos::MakeOffset( SMDS_ElemIteratorPtr theFaceIt,
TEPairVec& theNew2OldFaces, TEPairVec& theNew2OldFaces,
TNPairVec& theNew2OldNodes) TNPairVec& theNew2OldNodes)
{ {
if ( theSrcMesh.GetMeshInfo().NbFaces( ORDER_QUADRATIC ) > 0 )
throw SALOME_Exception( "Offset of quadratic mesh not supported" );
if ( theSrcMesh.GetMeshInfo().NbFaces() > theSrcMesh.GetMeshInfo().NbTriangles() )
throw SALOME_Exception( "Offset of non-triangular mesh not supported" );
SMDS_Mesh* newMesh = new SMDS_Mesh; SMDS_Mesh* newMesh = new SMDS_Mesh;
theNew2OldFaces.clear(); theNew2OldFaces.clear();
theNew2OldNodes.clear(); theNew2OldNodes.clear();
@ -2663,11 +2668,6 @@ SMDS_Mesh* SMESH_MeshAlgos::MakeOffset( SMDS_ElemIteratorPtr theFaceIt,
( std::make_pair(( const SMDS_MeshElement*) 0, ( std::make_pair(( const SMDS_MeshElement*) 0,
( const SMDS_MeshElement*) 0)); // to have index == face->GetID() ( const SMDS_MeshElement*) 0)); // to have index == face->GetID()
if ( theSrcMesh.GetMeshInfo().NbFaces( ORDER_QUADRATIC ) > 0 )
throw SALOME_Exception( "Offset of quadratic mesh not supported" );
if ( theSrcMesh.GetMeshInfo().NbFaces() > theSrcMesh.GetMeshInfo().NbTriangles() )
throw SALOME_Exception( "Offset of non-triangular mesh not supported" );
// copy input faces to the newMesh keeping IDs of nodes // copy input faces to the newMesh keeping IDs of nodes
double minNodeDist = 1e100; double minNodeDist = 1e100;

View File

@ -48,7 +48,7 @@ GENERATE_HTML = YES
HTML_OUTPUT = . HTML_OUTPUT = .
HTML_HEADER = @CMAKE_CURRENT_BINARY_DIR@/static/header.html HTML_HEADER = @CMAKE_CURRENT_BINARY_DIR@/static/header.html
HTML_FOOTER = @CMAKE_CURRENT_SOURCE_DIR@/static/footer.html HTML_FOOTER = @CMAKE_CURRENT_SOURCE_DIR@/static/footer.html
HTML_STYLESHEET = @CMAKE_CURRENT_SOURCE_DIR@/static/doxygen.css HTML_STYLESHEET = @CMAKE_CURRENT_SOURCE_DIR@/static/salome_extra.css
TOC_EXPAND = YES TOC_EXPAND = YES
DISABLE_INDEX = NO DISABLE_INDEX = NO
GENERATE_TREEVIEW = YES GENERATE_TREEVIEW = YES