+ /// Set the focus on the last item in the list
+ virtual void updateFocus();
+
+ /// Computes and updates name of selected object in the widget
+ virtual void updateSelectionName();
+
+ /// Retunrs a list of possible shape types
+ /// \return a list of shapes
+ virtual QIntList getShapeTypes() const;
+
+ /// Append the values to the model attribute of the widget. It casts this attribute to
+ /// the specific type and set the given values
+ /// \param theSelectedObject an object
+ /// \param theShape a selected shape, which is used in the selection attribute
+ /// \return true if it is succeed
+ void setObject(ObjectPtr theSelectedObject, GeomShapePtr theShape);
+
+ /// Creates a backup of the current values of the attribute
+ /// It should be realized in the specific widget because of different
+ /// parameters of the current attribute
+ /// \param theValid a boolean flag, if restore happens for valid parameters
+ virtual void restoreAttributeValue(const bool theValid);
+
+ /// Set current shape type for selection
+ void setCurrentShapeType(const TopAbs_ShapeEnum theShapeType);
+
+ /// Return the attribute values wrapped in a list of viewer presentations
+ /// \return a list of viewer presentations, which contains an attribute result and
+ /// a shape. If the attribute do not uses the shape, it is empty
+ virtual QList<ModuleBase_ViewerPrs> getAttributeSelection() const;
+
+ /// Fills the list control by the attribute values
+ void updateSelectionList();
+
+ /// Converts the XML defined type choice to the validator type
+ /// For example, the "Edges" is converted to "edge"
+ std::string validatorType(const QString& theType) const;
+
+protected:
+ /// Returns attribute indices selected in the widget selection list
+ /// \param theIndices a list of indices
+ void getSelectedAttributeIndices(std::set<int>& theIndices);
+
+ /// Gets the feature attribute and fill a list of viewer presentation for the attribute
+ /// indices. If the the container of indices is empty, it returns all objects.
+ /// \param theAttributeIds indices in attribute list to be returned
+ /// \param theValues the result presentations, filled with object and shape of an attribute item
+ void convertIndicesToViewerSelection(std::set<int> theAttributeIds,
+ QList<ModuleBase_ViewerPrs>& theValues) const;
+protected:
+ /// List control
+ QListWidget* myListControl;
+
+ /// Combobox of types
+ QComboBox* myTypeCombo;
+
+ /// Provides correspondance between Result object and its shape