Salome HOME
Merge remote-tracking branch 'origin/BR_1321_ECW' into BR_DEMO
[modules/hydro.git] / src / HYDROGUI / HYDROGUI_Polyline.h
index e14c54037ce2e1a69a11626bee066395f000ea97..ca41ae7cb827eadb74199a2b48d07e96a52f48bb 100644 (file)
@@ -1,8 +1,4 @@
-// Copyright (C) 2007-2015  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) 2014-2015  EDF-R&D
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
 // License as published by the Free Software Foundation; either
 #define _HYDROGUI_Polyline_HeaderFile
 
 #include <AIS_Shape.hxx>
-#include <AIS_InteractiveObject.hxx>
-
-#include <Standard.hxx>
-#include <Standard_DefineHandle.hxx>
-#include <PrsMgr_PresentationManager.hxx>
-#include <Handle_Prs3d_Presentation.hxx>
-#include <TCollection_AsciiString.hxx>
-#include <AIS_DisplayMode.hxx>
+#include <QList>
 
 class TopoDS_Shape;
+class TopoDS_Edge;
 
 class HYDROGUI_Polyline : public AIS_Shape
 {
 public:
-  
-  Standard_EXPORT HYDROGUI_Polyline(const TopoDS_Shape& shape);
-  Standard_EXPORT ~HYDROGUI_Polyline();
+  HYDROGUI_Polyline( const TopoDS_Shape& shape );
+  virtual ~HYDROGUI_Polyline();
 
-  Standard_EXPORT virtual void Compute(const Handle(PrsMgr_PresentationManager3d)& aPresentationManager,
+  virtual void Compute(const Handle(PrsMgr_PresentationManager3d)& aPresentationManager,
                                       const Handle(Prs3d_Presentation)& aPresentation,
                                       const Standard_Integer aMode = 0);
   
+  static QList<Handle(AIS_InteractiveObject)> createPresentations
+    ( const TopoDS_Shape& theShape, int theType, int theSize );
+  static void update( const QList<Handle(AIS_InteractiveObject)>&, int theType, int theSize );
+
 public:
-  DEFINE_STANDARD_RTTI(HYDROGUI_Polyline);
+  DEFINE_STANDARD_RTTIEXT(HYDROGUI_Polyline, AIS_Shape);
 };
 
-DEFINE_STANDARD_HANDLE(HYDROGUI_Polyline, AIS_Shape)
+class HYDROGUI_Arrow : public AIS_Shape
+{
+public:
+  enum Type { None, Triangle, Cone };
+
+  HYDROGUI_Arrow( const TopoDS_Edge& edge );
+  virtual ~HYDROGUI_Arrow();
+
+  virtual void Compute( const Handle(PrsMgr_PresentationManager3d)& aPresentationManager,
+                                               const Handle(Prs3d_Presentation)& aPresentation,
+                                               const Standard_Integer aMode = 0 );
+  
+  Type GetType() const;
+  void SetType( Type );
+
+  int  GetSize() const;
+  void SetSize( int );
+
+public:
+  DEFINE_STANDARD_RTTIEXT(HYDROGUI_Arrow, AIS_Shape);
+
+private:
+  Type myType;
+  int  mySize;
+};
 
 #endif