Salome HOME
projects
/
modules
/
smesh.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
c50bee3
)
0022308: EDF 2572 SMESH: Can't import a file with a non ascii character in the path
author
vsr
<vsr@opencascade.com>
Tue, 3 Sep 2013 10:58:47 +0000
(10:58 +0000)
committer
vsr
<vsr@opencascade.com>
Tue, 3 Sep 2013 10:58:47 +0000
(10:58 +0000)
src/SMESHGUI/SMESHGUI.cxx
patch
|
blob
|
history
diff --git
a/src/SMESHGUI/SMESHGUI.cxx
b/src/SMESHGUI/SMESHGUI.cxx
index 11eb2b89eeaa3ad656520d0773550255d81528c2..7c2eb1ace19da9a7f71fe189e9977aec3e074629 100644
(file)
--- a/
src/SMESHGUI/SMESHGUI.cxx
+++ b/
src/SMESHGUI/SMESHGUI.cxx
@@
-276,7
+276,7
@@
{
// UNV format
aMeshes->length( 1 );
{
// UNV format
aMeshes->length( 1 );
- aMeshes[0] = theComponentMesh->CreateMeshesFromUNV( filename.to
Latin1
().constData() );
+ aMeshes[0] = theComponentMesh->CreateMeshesFromUNV( filename.to
Utf8
().constData() );
if ( aMeshes[0]->_is_nil() )
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( "SMESH_ERR_UNKNOWN_IMPORT_ERROR" ) ) );
if ( aMeshes[0]->_is_nil() )
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( "SMESH_ERR_UNKNOWN_IMPORT_ERROR" ) ) );
@@
-286,7
+286,7
@@
{
// MED format
SMESH::DriverMED_ReadStatus res;
{
// MED format
SMESH::DriverMED_ReadStatus res;
- aMeshes = theComponentMesh->CreateMeshesFromMED( filename.to
Latin1
().constData(), res );
+ aMeshes = theComponentMesh->CreateMeshesFromMED( filename.to
Utf8
().constData(), res );
if ( res != SMESH::DRS_OK ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( QString( "SMESH_DRS_%1" ).arg( res ).toLatin1().data() ) ) );
if ( res != SMESH::DRS_OK ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( QString( "SMESH_DRS_%1" ).arg( res ).toLatin1().data() ) ) );
@@
-297,7
+297,7
@@
{
// STL format
aMeshes->length( 1 );
{
// STL format
aMeshes->length( 1 );
- aMeshes[0] = theComponentMesh->CreateMeshesFromSTL( filename.to
Latin1
().constData() );
+ aMeshes[0] = theComponentMesh->CreateMeshesFromSTL( filename.to
Utf8
().constData() );
if ( aMeshes[0]->_is_nil() ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( "SMESH_ERR_UNKNOWN_IMPORT_ERROR" ) ) );
if ( aMeshes[0]->_is_nil() ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( "SMESH_ERR_UNKNOWN_IMPORT_ERROR" ) ) );
@@
-308,7
+308,7
@@
{
// CGNS format
SMESH::DriverMED_ReadStatus res;
{
// CGNS format
SMESH::DriverMED_ReadStatus res;
- aMeshes = theComponentMesh->CreateMeshesFromCGNS( filename.to
Latin1
().constData(), res );
+ aMeshes = theComponentMesh->CreateMeshesFromCGNS( filename.to
Utf8
().constData(), res );
if ( res != SMESH::DRS_OK ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( QString( "SMESH_DRS_%1" ).arg( res ).toLatin1().data() ) ) );
if ( res != SMESH::DRS_OK ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( QString( "SMESH_DRS_%1" ).arg( res ).toLatin1().data() ) ) );
@@
-319,7
+319,7
@@
{
// SAUV format
SMESH::DriverMED_ReadStatus res;
{
// SAUV format
SMESH::DriverMED_ReadStatus res;
- aMeshes = theComponentMesh->CreateMeshesFromSAUV( filename.to
Latin1
().constData(), res );
+ aMeshes = theComponentMesh->CreateMeshesFromSAUV( filename.to
Utf8
().constData(), res );
if ( res != SMESH::DRS_OK ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( QString( "SMESH_DRS_%1" ).arg( res ).toLatin1().data() ) ) );
if ( res != SMESH::DRS_OK ) {
errors.append( QString( "%1 :\n\t%2" ).arg( filename ).
arg( QObject::tr( QString( "SMESH_DRS_%1" ).arg( res ).toLatin1().data() ) ) );
@@
-331,7
+331,7
@@
// GMF format
SMESH::ComputeError_var res;
aMeshes->length( 1 );
// GMF format
SMESH::ComputeError_var res;
aMeshes->length( 1 );
- aMeshes[0] = theComponentMesh->CreateMeshesFromGMF( filename.to
Latin1
().constData(),
+ aMeshes[0] = theComponentMesh->CreateMeshesFromGMF( filename.to
Utf8
().constData(),
toCreateGroups,
res.out() );
if ( res->code != SMESH::DRS_OK ) {
toCreateGroups,
res.out() );
if ( res->code != SMESH::DRS_OK ) {
@@
-727,7
+727,7
@@
if( !toOverwrite ) {
// can't append to an existing using other format
SMESH::MED_VERSION aVersion = SMESH::MED_V2_1;
if( !toOverwrite ) {
// can't append to an existing using other format
SMESH::MED_VERSION aVersion = SMESH::MED_V2_1;
- bool isVersionOk = SMESHGUI::GetSMESHGen()->GetMEDVersion( aFilename.to
Latin1
().constData(), aVersion );
+ bool isVersionOk = SMESHGUI::GetSMESHGen()->GetMEDVersion( aFilename.to
Utf8
().constData(), aVersion );
if( !isVersionOk || aVersion != aFormat ) {
int aRet = SUIT_MessageBox::warning(SMESHGUI::desktop(),
QObject::tr("SMESH_WRN_WARNING"),
if( !isVersionOk || aVersion != aFormat ) {
int aRet = SUIT_MessageBox::warning(SMESHGUI::desktop(),
QObject::tr("SMESH_WRN_WARNING"),
@@
-741,7
+741,7
@@
}
QStringList aMeshNamesCollisionList;
}
QStringList aMeshNamesCollisionList;
- SMESH::string_array_var aMeshNames = SMESHGUI::GetSMESHGen()->GetMeshNames( aFilename.to
Latin1
().constData() );
+ SMESH::string_array_var aMeshNames = SMESHGUI::GetSMESHGen()->GetMeshNames( aFilename.to
Utf8
().constData() );
for( int i = 0, n = aMeshNames->length(); i < n; i++ ) {
QString anExistingMeshName( aMeshNames[ i ] );
for( aMeshIter = aMeshList.begin(); aMeshIter != aMeshList.end(); aMeshIter++ ) {
for( int i = 0, n = aMeshNames->length(); i < n; i++ ) {
QString anExistingMeshName( aMeshNames[ i ] );
for( aMeshIter = aMeshList.begin(); aMeshIter != aMeshList.end(); aMeshIter++ ) {
@@
-807,10
+807,10
@@
SMESH::SMESH_IDSource_var aMeshOrGroup = (*aMeshIter).first;
SMESH::SMESH_Mesh_var aMeshItem = aMeshOrGroup->GetMesh();
if ( aMeshOrGroup->_is_equivalent( aMeshItem ))
SMESH::SMESH_IDSource_var aMeshOrGroup = (*aMeshIter).first;
SMESH::SMESH_Mesh_var aMeshItem = aMeshOrGroup->GetMesh();
if ( aMeshOrGroup->_is_equivalent( aMeshItem ))
- aMeshItem->ExportToMEDX( aFilename.to
Latin1
().data(), toCreateGroups,
+ aMeshItem->ExportToMEDX( aFilename.to
Utf8
().data(), toCreateGroups,
aFormat, toOverwrite && aMeshIndex == 0, toFindOutDim );
else
aFormat, toOverwrite && aMeshIndex == 0, toFindOutDim );
else
- aMeshItem->ExportPartToMED( aMeshOrGroup, aFilename.to
Latin1
().data(), toCreateGroups,
+ aMeshItem->ExportPartToMED( aMeshOrGroup, aFilename.to
Utf8
().data(), toCreateGroups,
aFormat, toOverwrite && aMeshIndex == 0, toFindOutDim );
}
}
aFormat, toOverwrite && aMeshIndex == 0, toFindOutDim );
}
}
@@
-820,29
+820,29
@@
{
SMESH::SMESH_Mesh_var aMeshItem = SMESH::SMESH_Mesh::_narrow( (*aMeshIter).first );
if( !aMeshItem->_is_nil() )
{
SMESH::SMESH_Mesh_var aMeshItem = SMESH::SMESH_Mesh::_narrow( (*aMeshIter).first );
if( !aMeshItem->_is_nil() )
- aMeshItem->ExportSAUV( aFilename.to
Latin1
().data(), toCreateGroups );
+ aMeshItem->ExportSAUV( aFilename.to
Utf8
().data(), toCreateGroups );
}
}
else if ( isDAT )
{
if ( aMeshOrGroup->_is_equivalent( aMesh ))
}
}
else if ( isDAT )
{
if ( aMeshOrGroup->_is_equivalent( aMesh ))
- aMesh->ExportDAT( aFilename.to
Latin1
().data() );
+ aMesh->ExportDAT( aFilename.to
Utf8
().data() );
else
else
- aMesh->ExportPartToDAT( aMeshOrGroup, aFilename.to
Latin1
().data() );
+ aMesh->ExportPartToDAT( aMeshOrGroup, aFilename.to
Utf8
().data() );
}
else if ( isUNV )
{
if ( aMeshOrGroup->_is_equivalent( aMesh ))
}
else if ( isUNV )
{
if ( aMeshOrGroup->_is_equivalent( aMesh ))
- aMesh->ExportUNV( aFilename.to
Latin1
().data() );
+ aMesh->ExportUNV( aFilename.to
Utf8
().data() );
else
else
- aMesh->ExportPartToUNV( aMeshOrGroup, aFilename.to
Latin1
().data() );
+ aMesh->ExportPartToUNV( aMeshOrGroup, aFilename.to
Utf8
().data() );
}
else if ( isSTL )
{
if ( aMeshOrGroup->_is_equivalent( aMesh ))
}
else if ( isSTL )
{
if ( aMeshOrGroup->_is_equivalent( aMesh ))
- aMesh->ExportSTL( aFilename.to
Latin1
().data(), aIsASCII_STL );
+ aMesh->ExportSTL( aFilename.to
Utf8
().data(), aIsASCII_STL );
else
else
- aMesh->ExportPartToSTL( aMeshOrGroup, aFilename.to
Latin1
().data(), aIsASCII_STL );
+ aMesh->ExportPartToSTL( aMeshOrGroup, aFilename.to
Utf8
().data(), aIsASCII_STL );
}
else if ( isCGNS )
{
}
else if ( isCGNS )
{
@@
-852,14
+852,14
@@
SMESH::SMESH_IDSource_var aMeshOrGroup = (*aMeshIter).first;
SMESH::SMESH_Mesh_var aMeshItem = aMeshOrGroup->GetMesh();
aMeshItem->ExportCGNS( aMeshOrGroup,
SMESH::SMESH_IDSource_var aMeshOrGroup = (*aMeshIter).first;
SMESH::SMESH_Mesh_var aMeshItem = aMeshOrGroup->GetMesh();
aMeshItem->ExportCGNS( aMeshOrGroup,
- aFilename.to
Latin1
().data(),
+ aFilename.to
Utf8
().data(),
toOverwrite && aMeshIndex == 0 );
}
}
else if ( isGMF )
{
toCreateGroups = true;
toOverwrite && aMeshIndex == 0 );
}
}
else if ( isGMF )
{
toCreateGroups = true;
- aMesh->ExportGMF( aMeshOrGroup, aFilename.to
Latin1
().data(), toCreateGroups );
+ aMesh->ExportGMF( aMeshOrGroup, aFilename.to
Utf8
().data(), toCreateGroups );
}
}
catch (const SALOME::SALOME_Exception& S_ex){
}
}
catch (const SALOME::SALOME_Exception& S_ex){