Salome HOME
Adding Naming DS for Placement operation.
[modules/shaper.git] / src / ModuleBase / ModuleBase_WidgetEditor.h
index e75d4cebda4b7c171b743359b64f6ba3b27d83c4..ded82628957ee54451f83046cd567772af409561 100644 (file)
@@ -20,13 +20,14 @@ class QLineEdit;
  */
 class MODULEBASE_EXPORT ModuleBase_WidgetEditor : public ModuleBase_WidgetDoubleValue
 {
-  Q_OBJECT
-public:
+Q_OBJECT
+ public:
   /// Constructor
   /// \theParent the parent object
   /// \theParent the parent object
   /// \theData the widget configuation. The attribute of the model widget is obtained from
-  ModuleBase_WidgetEditor(QWidget* theParent, const Config_WidgetAPI* theData);
+  ModuleBase_WidgetEditor(QWidget* theParent, const Config_WidgetAPI* theData,
+                          const std::string& theParentId);
   /// Constructor
   /// \theParent the parent object
   /// \theParent the parent object
@@ -38,16 +39,21 @@ public:
 
   /// Set focus to the first control of the current widget. The focus policy of the control is checked.
   /// If the widget has the NonFocus focus policy, it is skipped.
-  virtual void focusTo();
+  /// \return the state whether the widget can accept the focus
+  virtual bool focusTo();
 
   /// Creates an editor for the real value and set the new value to the feature
   /// \param theFeature the model feature
   /// \param theAttribute the feature attribute
   static void editFeatureValue(FeaturePtr theFeature, const std::string theAttribute);
 
-private:
-  FeaturePtr myFeature; ///< the current widget feature
-  QStringList myFeatureKinds; ///< the kinds of possible features
+ private slots:
+   /// Shous popup window under cursor for data editing
+   void showPopupEditor();
+
+ private:
+  FeaturePtr myFeature;  ///< the current widget feature
+  QStringList myFeatureKinds;  ///< the kinds of possible features
 };
 
 #endif