Salome HOME
projects
/
modules
/
smesh.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Replace shape in Mesh object
[modules/smesh.git]
/
src
/
SMESH
/
SMESH_Gen.cxx
diff --git
a/src/SMESH/SMESH_Gen.cxx
b/src/SMESH/SMESH_Gen.cxx
index 27881281ed5f593b839a0561cdea0d6f2b2e56d1..1e9c1471a1e404d52c46ef6385ab35fb437f9ca9 100644
(file)
--- a/
src/SMESH/SMESH_Gen.cxx
+++ b/
src/SMESH/SMESH_Gen.cxx
@@
-1,4
+1,4
@@
-// Copyright (C) 2007-201
6
CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-201
9
CEA/DEN, EDF R&D, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@
-20,7
+20,7
@@
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
//
-// SMESH SMESH : implementaion of SMESH idl descriptions
+// SMESH SMESH : implementa
t
ion of SMESH idl descriptions
// File : SMESH_Gen.cxx
// Author : Paul RASCLE, EDF
// Module : SMESH
// File : SMESH_Gen.cxx
// Author : Paul RASCLE, EDF
// Module : SMESH
@@
-52,10
+52,9
@@
#include <windows.h>
#endif
#include <windows.h>
#endif
-using namespace std;
-
-//#include <vtkDebugLeaks.h>
+#include <Basics_Utils.hxx>
+using namespace std;
//=============================================================================
/*!
//=============================================================================
/*!
@@
-70,9
+69,7
@@
SMESH_Gen::SMESH_Gen()
_localId = 0;
_hypId = 0;
_segmentation = _nbSegments = 10;
_localId = 0;
_hypId = 0;
_segmentation = _nbSegments = 10;
- SMDS_Mesh::_meshList.clear();
_compute_canceled = false;
_compute_canceled = false;
- //vtkDebugLeaks::SetExitError(0);
}
namespace
}
namespace
@@
-96,12
+93,12
@@
namespace
SMESH_Gen::~SMESH_Gen()
{
SMESH_Gen::~SMESH_Gen()
{
-
std::map < int, SMESH_Hypothesis * >::iterator i_hyp = _studyContext->mapHypothesis.begin();
-
for ( ; i_hyp != _studyContext->mapHypothesis.end(); ++i_hyp )
-
{
-
if ( _Hyp* h = static_cast< _Hyp*>( i_hyp->second ))
-
h->NullifyGen();
-
}
+ std::map < int, SMESH_Hypothesis * >::iterator i_hyp = _studyContext->mapHypothesis.begin();
+ for ( ; i_hyp != _studyContext->mapHypothesis.end(); ++i_hyp )
+ {
+ if ( _Hyp* h = static_cast< _Hyp*>( i_hyp->second ))
+ h->NullifyGen();
+ }
delete _studyContext->myDocument;
delete _studyContext;
}
delete _studyContext->myDocument;
delete _studyContext;
}
@@
-400,8
+397,10
@@
bool SMESH_Gen::Compute(SMESH_Mesh & aMesh,
}
if ( aCompactMesh )
}
if ( aCompactMesh )
- aMesh.GetMeshDS()->compactMesh();
-
+ {
+ aMesh.GetMeshDS()->Modified();
+ aMesh.GetMeshDS()->CompactMesh();
+ }
return ret;
}
return ret;
}
@@
-668,7
+667,7
@@
static bool checkConformIgnoredAlgos(SMESH_Mesh& aMesh,
checkConform = false; // no more check conformity
INFOS( "ERROR: Local <" << algo->GetName() <<
"> would produce not conform mesh: "
checkConform = false; // no more check conformity
INFOS( "ERROR: Local <" << algo->GetName() <<
"> would produce not conform mesh: "
- "<Not Conform Mesh Allowed> hypotesis is missing");
+ "<Not Conform Mesh Allowed> hypot
h
esis is missing");
theErrors.push_back( SMESH_Gen::TAlgoStateError() );
theErrors.back().Set( SMESH_Hypothesis::HYP_NOTCONFORM, algo, false );
}
theErrors.push_back( SMESH_Gen::TAlgoStateError() );
theErrors.back().Set( SMESH_Hypothesis::HYP_NOTCONFORM, algo, false );
}
@@
-1032,7
+1031,15
@@
std::vector< std::string > SMESH_Gen::GetPluginXMLPaths()
xmlPath += sep + plugin + ".xml";
bool fileOK;
#ifdef WIN32
xmlPath += sep + plugin + ".xml";
bool fileOK;
#ifdef WIN32
- fileOK = (GetFileAttributes(xmlPath.c_str()) != INVALID_FILE_ATTRIBUTES);
+#ifdef UNICODE
+ const wchar_t* path = Kernel_Utils::decode_s(xmlPath);
+#else
+ const char* path = xmlPath.c_str();
+#endif
+ fileOK = (GetFileAttributes(path) != INVALID_FILE_ATTRIBUTES);
+#ifdef UNICODE
+ delete path;
+#endif
#else
fileOK = (access(xmlPath.c_str(), F_OK) == 0);
#endif
#else
fileOK = (access(xmlPath.c_str(), F_OK) == 0);
#endif
@@
-1173,7
+1180,7
@@
int SMESH_Gen::GetShapeDim(const TopAbs_ShapeEnum & aShapeType)
//=============================================================================
/*!
//=============================================================================
/*!
- * Gen
a
rate a new id unique within this Gen
+ * Gen
e
rate a new id unique within this Gen
*/
//=============================================================================
*/
//=============================================================================