From e2fb39b930030d007173a93fc283d6c02addb45d Mon Sep 17 00:00:00 2001 From: asv Date: Tue, 30 Aug 2005 06:01:19 +0000 Subject: [PATCH] compilation errors on Mandrake fixed (clashes of CASCADE's min/max definitions and std::min/std::max). --- src/SVTK/SVTK_InteractorStyle.cxx | 4 ++++ src/SVTK/SVTK_View.cxx | 2 +- src/SVTK/SVTK_View.h | 6 ++++-- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/SVTK/SVTK_InteractorStyle.cxx b/src/SVTK/SVTK_InteractorStyle.cxx index 1925bd2a5..bb67274d4 100644 --- a/src/SVTK/SVTK_InteractorStyle.cxx +++ b/src/SVTK/SVTK_InteractorStyle.cxx @@ -66,6 +66,10 @@ //VRV: porting on Qt 3.0.5 #include +// undefining min and max because CASCADE's Xw_Extensions.hxx defines them and +// it clashes with std::min(), std::max() included in utilities.h +#undef min +#undef max #include "utilities.h" using namespace std; diff --git a/src/SVTK/SVTK_View.cxx b/src/SVTK/SVTK_View.cxx index f886bbf92..a29e0b4e7 100644 --- a/src/SVTK/SVTK_View.cxx +++ b/src/SVTK/SVTK_View.cxx @@ -301,5 +301,5 @@ SVTK_InteractorStyle* SVTK_View ::getInteractorStyle() { - return myInteractorStyles.empty() ? 0 : myInteractorStyles.top().GetPointer(); + return myInteractorStyles.isEmpty() ? 0 : myInteractorStyles.top().GetPointer(); } diff --git a/src/SVTK/SVTK_View.h b/src/SVTK/SVTK_View.h index 76079a6a9..e1229a18d 100644 --- a/src/SVTK/SVTK_View.h +++ b/src/SVTK/SVTK_View.h @@ -6,14 +6,16 @@ #endif #include "SVTK.h" + #include "SVTK_Selection.h" #include "SVTK_RenderWindowInteractor.h" + #include "SALOME_InteractiveObject.hxx" #include -#include +#include class vtkCallbackCommand; class VTKViewer_Actor; @@ -105,7 +107,7 @@ protected: void initInteractorStyle( SVTK_InteractorStyle* ); typedef vtkSmartPointer PInteractorStyle; - std::stack myInteractorStyles; + QValueStack myInteractorStyles; }; #ifdef WIN32 -- 2.39.2