+//================================================================================
+/*!
+ * \brief Connect selection slots
+ * \param other - another StdMeshersGUI_ObjectReferenceParamWdg
+ */
+//================================================================================
+
+void StdMeshersGUI_SubShapeSelectorWdg::
+AvoidSimultaneousSelection ( StdMeshersGUI_SubShapeSelectorWdg* other)
+{
+ connect(other, SIGNAL(selectionActivated()), this, SLOT(deactivateSelection()));
+ connect(this, SIGNAL(selectionActivated()), other, SLOT(deactivateSelection()));
+}
+
+//================================================================================
+/*!
+ * \brief Connect/disconnect to change of selection
+ */
+//================================================================================
+
+void StdMeshersGUI_SubShapeSelectorWdg::ActivateSelection( bool toActivate )
+{
+ // adjust state of myActivateButton
+ if ( myActivateButton &&
+ myActivateButton != sender() &&
+ myActivateButton->isChecked() != toActivate )
+ {
+ myActivateButton->toggle();
+ return;
+ }
+
+ if ( !mySelectionMgr ) return;
+
+ if ( toActivate )
+ {
+ connect( mySelectionMgr, SIGNAL(currentSelectionChanged()), SLOT(selectionIntoArgument()));
+ }
+ else
+ {
+ disconnect(mySelectionMgr, 0, this, 0 );
+ }
+
+ if ( sender() == myActivateButton )
+ ShowPreview( toActivate );
+
+ if ( toActivate )
+ emit selectionActivated();
+}
+
+//================================================================================
+/*!
+ * \brief Clears selected IDs. This is a workaround of a bug that
+ * SUIT_SelectionMgr::clearSelected() does not emit currentSelectionChanged
+ */
+//================================================================================
+
+void StdMeshersGUI_SubShapeSelectorWdg::ClearSelected()
+{
+ mySelectedIDs.clear();
+ selectionIntoArgument();
+}
+