/// \returns true if the action is processed\r
virtual bool deleteObjects() { return false; };\r
\r
+ /// Returns data model object for representation of data tree in Object browser\r
+ virtual ModuleBase_IDocumentDataModel* dataModel() const = 0;\r
+\r
+ /// Returns a list of modes, where the AIS objects should be activated\r
+ /// \param theModes a list of modes\r
+ virtual void activeSelectionModes(QIntList& theModes) {};\r
+ \r
public slots:\r
/// Called on call of command corresponded to a feature\r
void onFeatureTriggered();\r
#include <ModuleBase_IPropertyPanel.h>
#include <ModuleBase_WidgetEditor.h>
#include <ModuleBase_FilterFactory.h>
- #include <GeomValidators_Edge.h>
- #include <GeomValidators_EdgeOrVertex.h>
+#include <ModuleBase_Tools.h>
+ #include <GeomValidators_ShapeType.h>
+
#include <GeomValidators_Face.h>
#include <GeomValidators_ConstructionComposite.h>
}
-bool PartSet_Module::addViewerItems(QMenu* theMenu, const QMap<QString, QAction*>& theStdActions) const
+bool PartSet_Module::addViewerMenu(QMenu* theMenu, const QMap<QString, QAction*>& theStdActions) const
{
- return myMenuMgr->addViewerItems(theMenu, theStdActions);
+ return myMenuMgr->addViewerMenu(theMenu, theStdActions);
}
+ void PartSet_Module::activeSelectionModes(QIntList& theModes)
+ {
+ theModes.clear();
+ if (mySketchMgr->activeSketch().get())
+ PartSet_SketcherMgr::sketchSelectionModes(theModes);
+ }
+
bool PartSet_Module::isMouseOverWindow()
{
return mySketchMgr->isMouseOverWindow();
/// \param theMenu a popup menu to be shown in the viewer
/// \param theStdActions a map of standard actions
/// \return true if items are added and there is no necessity to provide standard menu
- virtual bool addViewerItems(QMenu* theMenu, const QMap<QString, QAction*>& theStdActions) const;
+ virtual bool addViewerMenu(QMenu* theMenu, const QMap<QString, QAction*>& theStdActions) const;
+ /// Returns a list of modes, where the AIS objects should be activated
+ /// \param theModes a list of modes
+ virtual void activeSelectionModes(QIntList& theModes);
+
/// Returns whether the mouse enter the viewer's window
/// \return true if items are added and there is no necessity to provide standard menu
bool isMouseOverWindow();