Salome HOME
037be3bd01f6a644508db9b88e2b05a74bc999f5
[modules/shaper.git] / src / ModuleBase / ModuleBase_ISelection.h
1 // File:        ModuleBase_ISelection.h
2 // Created:     2 June 2014
3 // Author:      Vitaly Smetannikov
4
5 #ifndef ModuleBase_ISelection_H
6 #define ModuleBase_ISelection_H
7
8 #include "ModuleBase.h"
9 #include "ModuleBase_Definitions.h"
10 #include "ModuleBase_ViewerPrs.h"
11
12 #include <QModelIndexList>
13 #include <AIS_ListOfInteractive.hxx>
14 #include <NCollection_List.hxx>
15 #include <TopoDS_Shape.hxx>
16
17 #include <QList>
18
19 class ModuleBase_ISelection
20 {
21  public:
22
23   /// Returns a list of viewer selected presentations
24   /// \param theShapeTypeToSkip the shapes with this type will be skipped during the result list build
25   /// \return list of presentations
26   virtual QList<ModuleBase_ViewerPrs> getSelected(int theShapeTypeToSkip = -1) const = 0;
27
28   /// Returns a list of viewer highlited presentations
29   /// \param theShapeTypeToSkip the shapes with this type will be skipped during the result list build
30   /// \return list of presentations
31   virtual QList<ModuleBase_ViewerPrs> getHighlighted(int theShapeTypeToSkip = -1) const = 0;
32
33   /**
34    * Returns list of features currently selected in object browser
35    */
36   virtual QObjectPtrList selectedObjects() const = 0;
37
38   /**
39    * Returns list of currently selected results
40    */
41   virtual QObjectPtrList selectedPresentations() const = 0;
42
43   //! Returns list of currently selected QModelIndexes
44   virtual QModelIndexList selectedIndexes() const = 0;
45
46   //! Returns list of currently selected AIS objects
47   virtual void selectedAISObjects(AIS_ListOfInteractive& theList) const = 0;
48
49   //! Returns list of currently selected shapes
50   virtual void selectedShapes(NCollection_List<TopoDS_Shape>& theList, 
51     std::list<ObjectPtr>& theOwners) const = 0;
52
53 };
54
55 #endif