#include <ModuleBase_Operation.h>
#include <QObject>
+#include <map>
+
class Handle_V3d_View;
class QMouseEvent;
class GeomAPI_Shape;
/// \param theFeature the feature object to obtain the preview
boost::shared_ptr<GeomAPI_Shape> preview(boost::shared_ptr<ModelAPI_Feature> theFeature) const;
+ /// Returns the map of the operation previews including the nested feature previews
+ /// \return the map of feature to the feature preview
+ virtual std::map<boost::shared_ptr<ModelAPI_Feature>, boost::shared_ptr<GeomAPI_Shape> > preview() const;
+
/// Returns the operation local selection mode
/// \param theFeature the feature object to get the selection mode
/// \return the selection mode
/// Initializes some fields accorging to the feature
/// \param theFeature the feature
- virtual void init(boost::shared_ptr<ModelAPI_Feature> theFeature) {}
+ /// \param thePresentations the list of additional presentations
+ virtual void init(boost::shared_ptr<ModelAPI_Feature> theFeature,
+ const std::list<XGUI_ViewerPrs>& thePresentations) {}
/// Processes the mouse pressed in the point
/// \param thePoint a point clicked in the viewer
/// \param theEvent the mouse event
- virtual void mousePressed(QMouseEvent* theEvent, Handle_V3d_View theView);
+ /// \param theSelected the list of selected presentations
+ virtual void mousePressed(QMouseEvent* theEvent, Handle_V3d_View theView,
+ const std::list<XGUI_ViewerPrs>& theSelected);
/// Processes the mouse release in the point
/// \param thePoint a point clicked in the viewer
/// Processes the mouse move in the point
/// \param thePoint a 3D point clicked in the viewer
/// \param theEvent the mouse event
- /// \param theSelected the list of selected presentations
- virtual void mouseMoved(QMouseEvent* theEvent, Handle_V3d_View theView,
- const std::list<XGUI_ViewerPrs>& theSelected);
+ virtual void mouseMoved(QMouseEvent* theEvent, Handle_V3d_View theView);
/// Processes the key pressed in the view
/// \param theKey a key value
/// \param theMode the mode of the feature modification
void featureConstructed(boost::shared_ptr<ModelAPI_Feature> theFeature,
int theMode);
+ /// Signal about the features should be selected
+ /// \param theSelected the list of selected presentations
+ void featureSelected(const std::list<XGUI_ViewerPrs>& theSelected);
/// signal about the request to launch operation
/// theName the operation name
/// theFeature the operation argument