mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-04-08 17:17:26 +05:00
Merge from V7_3_BR_WIN
This commit is contained in:
parent
49638e2cad
commit
a2e2cffeb3
@ -69,9 +69,12 @@
|
|||||||
#include "SMESH_TryCatch.hxx" // include after OCCT headers!
|
#include "SMESH_TryCatch.hxx" // include after OCCT headers!
|
||||||
|
|
||||||
#include "Utils_ExceptHandlers.hxx"
|
#include "Utils_ExceptHandlers.hxx"
|
||||||
|
#ifndef WIN32
|
||||||
#include <boost/thread/thread.hpp>
|
#include <boost/thread/thread.hpp>
|
||||||
#include <boost/bind.hpp>
|
#include <boost/bind.hpp>
|
||||||
|
#else
|
||||||
|
#include <pthread.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
@ -139,11 +142,23 @@ SMESH_Mesh::SMESH_Mesh():
|
|||||||
|
|
||||||
namespace
|
namespace
|
||||||
{
|
{
|
||||||
void deleteMeshDS(SMESHDS_Mesh* meshDS)
|
#ifndef WIN32
|
||||||
|
void deleteMeshDS(SMESHDS_Mesh* meshDS)
|
||||||
{
|
{
|
||||||
//cout << "deleteMeshDS( " << meshDS << endl;
|
//cout << "deleteMeshDS( " << meshDS << endl;
|
||||||
delete meshDS;
|
delete meshDS;
|
||||||
}
|
}
|
||||||
|
#else
|
||||||
|
static void* deleteMeshDS(void* meshDS)
|
||||||
|
{
|
||||||
|
//cout << "deleteMeshDS( " << meshDS << endl;
|
||||||
|
SMESHDS_Mesh* m = (SMESHDS_Mesh*)meshDS;
|
||||||
|
if(m) {
|
||||||
|
delete m;
|
||||||
|
}
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
//=============================================================================
|
//=============================================================================
|
||||||
@ -191,9 +206,15 @@ SMESH_Mesh::~SMESH_Mesh()
|
|||||||
_myDocument->RemoveMesh( _id );
|
_myDocument->RemoveMesh( _id );
|
||||||
_myDocument = 0;
|
_myDocument = 0;
|
||||||
|
|
||||||
if ( _myMeshDS )
|
if ( _myMeshDS ) {
|
||||||
// delete _myMeshDS, in a thread in order not to block closing a study with large meshes
|
// delete _myMeshDS, in a thread in order not to block closing a study with large meshes
|
||||||
|
#ifndef WIN32
|
||||||
boost::thread aThread(boost::bind( & deleteMeshDS, _myMeshDS ));
|
boost::thread aThread(boost::bind( & deleteMeshDS, _myMeshDS ));
|
||||||
|
#else
|
||||||
|
pthread_t thread;
|
||||||
|
int result=pthread_create(&thread, NULL, deleteMeshDS, (void*)_myMeshDS);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//================================================================================
|
//================================================================================
|
||||||
|
@ -748,10 +748,12 @@ SMESHGUI_ComputeDlg_QThreadQDialog::SMESHGUI_ComputeDlg_QThreadQDialog(QWidget
|
|||||||
|
|
||||||
QLabel * nbNodesName = new QLabel(tr("SMESH_MESHINFO_NODES"), this );
|
QLabel * nbNodesName = new QLabel(tr("SMESH_MESHINFO_NODES"), this );
|
||||||
QLabel * nbElemsName = new QLabel(tr("SMESH_MESHINFO_ELEMENTS"), this );
|
QLabel * nbElemsName = new QLabel(tr("SMESH_MESHINFO_ELEMENTS"), this );
|
||||||
QLabel * freeRAMName = new QLabel(tr("SMESH_FREERAM"), this );
|
|
||||||
nbNodesLabel = new QLabel("0", this );
|
nbNodesLabel = new QLabel("0", this );
|
||||||
nbElemsLabel = new QLabel("0", this );
|
nbElemsLabel = new QLabel("0", this );
|
||||||
|
#ifndef WIN32
|
||||||
|
QLabel * freeRAMName = new QLabel(tr("SMESH_FREERAM"), this );
|
||||||
freeRAMLabel = new QLabel("", this );
|
freeRAMLabel = new QLabel("", this );
|
||||||
|
#endif
|
||||||
progressBar = new QProgressBar(this);
|
progressBar = new QProgressBar(this);
|
||||||
progressBar->setMinimum( 0 );
|
progressBar->setMinimum( 0 );
|
||||||
progressBar->setMaximum( 1000 );
|
progressBar->setMaximum( 1000 );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user