From c6130fee7bd3a8aa436e5c7dfbc9bf35b562f722 Mon Sep 17 00:00:00 2001 From: abd Date: Tue, 7 Oct 2008 13:30:33 +0000 Subject: [PATCH] Fix compilation problems on Win32 Platform --- src/SMESH/SMESH_Block.cxx | 2 -- src/SMESH/SMESH_Pattern.cxx | 2 -- src/SMESHGUI/SMESHGUI_EditHypothesesDlg.h | 2 +- src/SMESHGUI/SMESHGUI_FileInfoDlg.cxx | 2 -- src/SMESHGUI/SMESHGUI_MeshUtils.cxx | 2 +- src/StdMeshers/StdMeshers_Penta_3D.cxx | 2 -- src/StdMeshers/StdMeshers_ProjectionUtils.cxx | 4 ++-- src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cxx | 4 ++-- src/StdMeshers/StdMeshers_UseExisting_1D2D.hxx | 2 +- src/StdMeshers_I/StdMeshers_ProjectionSource1D_i.cxx | 6 ++++-- 10 files changed, 11 insertions(+), 17 deletions(-) diff --git a/src/SMESH/SMESH_Block.cxx b/src/SMESH/SMESH_Block.cxx index bf85ab033..e5507bdd9 100644 --- a/src/SMESH/SMESH_Block.cxx +++ b/src/SMESH/SMESH_Block.cxx @@ -21,8 +21,6 @@ // Created : Mon Aug 2 10:30:00 2004 // Author : Edward AGAPOV (eap) -using namespace std; - #include "SMESH_Block.hxx" #include diff --git a/src/SMESH/SMESH_Pattern.cxx b/src/SMESH/SMESH_Pattern.cxx index 40d7bf57f..b8dd698a1 100644 --- a/src/SMESH/SMESH_Pattern.cxx +++ b/src/SMESH/SMESH_Pattern.cxx @@ -21,8 +21,6 @@ // Created : Mon Aug 2 10:30:00 2004 // Author : Edward AGAPOV (eap) -using namespace std; - #include "SMESH_Pattern.hxx" #include diff --git a/src/SMESHGUI/SMESHGUI_EditHypothesesDlg.h b/src/SMESHGUI/SMESHGUI_EditHypothesesDlg.h index 7385dcb9f..30907b840 100644 --- a/src/SMESHGUI/SMESHGUI_EditHypothesesDlg.h +++ b/src/SMESHGUI/SMESHGUI_EditHypothesesDlg.h @@ -54,7 +54,7 @@ class QListBox; class QListBoxItem; class SMESHGUI; -typedef map MapIOR; +typedef std::map MapIOR; //================================================================================= // class : SMESHGUI_EditHypothesesDlg diff --git a/src/SMESHGUI/SMESHGUI_FileInfoDlg.cxx b/src/SMESHGUI/SMESHGUI_FileInfoDlg.cxx index f744561d3..a2ba3dc21 100644 --- a/src/SMESHGUI/SMESHGUI_FileInfoDlg.cxx +++ b/src/SMESHGUI/SMESHGUI_FileInfoDlg.cxx @@ -26,8 +26,6 @@ #include -#include - #include #include #include diff --git a/src/SMESHGUI/SMESHGUI_MeshUtils.cxx b/src/SMESHGUI/SMESHGUI_MeshUtils.cxx index ccbdaff7d..fafbf8cb1 100644 --- a/src/SMESHGUI/SMESHGUI_MeshUtils.cxx +++ b/src/SMESHGUI/SMESHGUI_MeshUtils.cxx @@ -56,7 +56,7 @@ namespace SMESH QString name = baseName; while ( !aStudy->FindObjectByName( name.latin1(), "SMESH" ).empty() ) { int nb = 0; - if ( name[ name.length()-1 ].isNumber() ) { + if ( name.at( name.length()-1 ).isNumber() ) { int nbBeg = name.findRev("_"); nb = name.right( name.length() - nbBeg - 1 ).toInt(); name = name.left( nbBeg ); diff --git a/src/StdMeshers/StdMeshers_Penta_3D.cxx b/src/StdMeshers/StdMeshers_Penta_3D.cxx index 8f3d233a2..4030cdfce 100644 --- a/src/StdMeshers/StdMeshers_Penta_3D.cxx +++ b/src/StdMeshers/StdMeshers_Penta_3D.cxx @@ -24,8 +24,6 @@ // File : StdMeshers_Penta_3D.cxx // Module : SMESH -using namespace std; - #include "StdMeshers_Penta_3D.hxx" #include "utilities.h" diff --git a/src/StdMeshers/StdMeshers_ProjectionUtils.cxx b/src/StdMeshers/StdMeshers_ProjectionUtils.cxx index 1ef60301f..550ecb2e5 100644 --- a/src/StdMeshers/StdMeshers_ProjectionUtils.cxx +++ b/src/StdMeshers/StdMeshers_ProjectionUtils.cxx @@ -25,8 +25,6 @@ // Created : Fri Oct 27 10:24:28 2006 // Author : Edward AGAPOV (eap) -using namespace std; - #include "StdMeshers_ProjectionUtils.hxx" #include "StdMeshers_ProjectionSource1D.hxx" @@ -66,6 +64,8 @@ using namespace std; #include #include +using namespace std; + #define RETURN_BAD_RESULT(msg) { MESSAGE(")-: Error: " << msg); return false; } #define SHOW_VERTEX(v,msg) // { \ diff --git a/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cxx b/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cxx index 13bbf2581..f511e6475 100644 --- a/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cxx +++ b/src/StdMeshers/StdMeshers_QuadToTriaAdaptor.cxx @@ -1007,7 +1007,7 @@ bool StdMeshers_QuadToTriaAdaptor::Compute2ndPart(SMESH_Mesh& aMesh) std::list triasI = (*itrmI).second; std::list::iterator ittI = triasI.begin(); int nbfI = triasI.size(); - const SMDS_FaceOfNodes* FsI[nbfI]; + vector FsI(nbfI); k = 0; for(; ittI!=triasI.end(); ittI++) { FsI[k] = (*ittI); @@ -1025,7 +1025,7 @@ bool StdMeshers_QuadToTriaAdaptor::Compute2ndPart(SMESH_Mesh& aMesh) std::list triasJ = (*itrmJ).second; std::list::iterator ittJ = triasJ.begin(); int nbfJ = triasJ.size(); - const SMDS_FaceOfNodes* FsJ[nbfJ]; + vector FsJ(nbfJ); k = 0; for(; ittJ!=triasJ.end(); ittJ++) { FsJ[k] = (*ittJ); diff --git a/src/StdMeshers/StdMeshers_UseExisting_1D2D.hxx b/src/StdMeshers/StdMeshers_UseExisting_1D2D.hxx index e0eedabdb..780d97d83 100644 --- a/src/StdMeshers/StdMeshers_UseExisting_1D2D.hxx +++ b/src/StdMeshers/StdMeshers_UseExisting_1D2D.hxx @@ -49,7 +49,7 @@ public: }; -class StdMeshers_UseExisting_1D: public SMESH_1D_Algo +class STDMESHERS_EXPORT StdMeshers_UseExisting_1D: public SMESH_1D_Algo { public: StdMeshers_UseExisting_1D(int hypId, int studyId, SMESH_Gen* gen); diff --git a/src/StdMeshers_I/StdMeshers_ProjectionSource1D_i.cxx b/src/StdMeshers_I/StdMeshers_ProjectionSource1D_i.cxx index e3d5f4eeb..aadc1b6d4 100644 --- a/src/StdMeshers_I/StdMeshers_ProjectionSource1D_i.cxx +++ b/src/StdMeshers_I/StdMeshers_ProjectionSource1D_i.cxx @@ -26,8 +26,6 @@ // Module : SMESH // $Header$ -using namespace std; - #include "StdMeshers_ProjectionSource1D_i.hxx" #include "SMESH_Gen_i.hxx" @@ -39,6 +37,10 @@ using namespace std; #include "StdMeshers_ObjRefUlils.hxx" +using namespace std; + + + //============================================================================= /*! * StdMeshers_ProjectionSource1D_i::StdMeshers_ProjectionSource1D_i -- 2.39.2