1 #ifndef XGUI_SALOMEVIEWER_H
2 #define XGUI_SALOMEVIEWER_H
7 #include <AIS_InteractiveContext.hxx>
8 #include <V3d_View.hxx>
12 class QContextMenuEvent;
15 * A Base object for definition of connector object to
16 * Salome Viewer. Reimplemented in NewGeom_SalomeViewer class
18 class XGUI_EXPORT XGUI_SalomeViewer : public QObject
22 XGUI_SalomeViewer(QObject* theParent)
27 //! Returns AIS_InteractiveContext from current OCCViewer
28 virtual Handle(AIS_InteractiveContext) AISContext() const = 0;
30 //! Retrurns V3d_Vioewer from current viewer
31 virtual Handle(V3d_Viewer) v3dViewer() const = 0;
33 //! Returns Vsd_View object from currently active view window
34 virtual Handle(V3d_View) activeView() const = 0;
36 //! Enable or disable selection in the viewer
37 virtual void enableSelection(bool isEnabled) = 0;
39 //! Returns true if selection is enabled
40 virtual bool isSelectionEnabled() const = 0;
42 //! Enable or disable multiselection in the viewer
43 virtual void enableMultiselection(bool isEnable) = 0;
45 //! Returns true if multiselection is enabled
46 virtual bool isMultiSelectionEnabled() const = 0;
48 //! Perfroms the fit all for the active view
49 virtual void fitAll() = 0;
52 void lastViewClosed();
56 void mousePress(QMouseEvent* theEvent);
57 void mouseRelease(QMouseEvent* theEvent);
58 void mouseDoubleClick(QMouseEvent* theEvent);
59 void mouseMove(QMouseEvent* theEvent);
60 void keyPress(QKeyEvent* theEvent);
61 void keyRelease(QKeyEvent* theEvent);
64 void selectionChanged();
65 void contextMenuRequested(QContextMenuEvent*);