Salome HOME
Issue #2156 Impossible to valid the sketch: better debug information about store...
[modules/shaper.git] / src / ModuleBase / ModuleBase_WidgetShapeSelector.cpp
index 013b89d3c9b74063bb472513cafe5fa04b9f0aa3..22955490032bc9e558c61f4426170c01c4a1f25d 100644 (file)
 #include <ModuleBase_IWorkshop.h>
 #include <ModuleBase_IViewer.h>
 #include <ModuleBase_Tools.h>
-#include <ModuleBase_FilterFactory.h>
 #include <ModuleBase_Filter.h>
 #include <ModuleBase_IModule.h>
 #include <ModuleBase_ViewerPrs.h>
 #include <ModuleBase_IconFactory.h>
 
+#include <Config_Translator.h>
 #include <Config_WidgetAPI.h>
 #include <Events_Loop.h>
 #include <Events_Message.h>
@@ -39,7 +39,6 @@
 #include <ModelAPI_AttributeValidator.h>
 
 #include <Config_WidgetAPI.h>
-#include <Events_Error.h>
 
 #include <GeomAPI_Shape.h>
 
@@ -74,14 +73,14 @@ ModuleBase_WidgetShapeSelector::ModuleBase_WidgetShapeSelector(QWidget* theParen
   QFormLayout* aLayout = new QFormLayout(this);
   ModuleBase_Tools::adjustMargins(aLayout);
 
-  QString aLabelText = QString::fromStdString(theData->widgetLabel());
+  QString aLabelText = translate(theData->widgetLabel());
   QString aLabelIcon = QString::fromStdString(theData->widgetIcon());
   myLabel = new QLabel(aLabelText, this);
   if (!aLabelIcon.isEmpty())
     myLabel->setPixmap(ModuleBase_IconFactory::loadPixmap(aLabelIcon));
 
 
-  QString aToolTip = QString::fromStdString(theData->widgetTooltip());
+  QString aToolTip = translate(theData->widgetTooltip());
   myTextLine = new QLineEdit(this);
   QString anObjName = QString::fromStdString(attributeID());
   myTextLine->setObjectName(anObjName);
@@ -104,7 +103,7 @@ ModuleBase_WidgetShapeSelector::~ModuleBase_WidgetShapeSelector()
 //********************************************************************
 bool ModuleBase_WidgetShapeSelector::storeValueCustom()
 {
-  // the value is stored on the selection changed signal processing 
+  // the value is stored on the selection changed signal processing
   return true;
 }
 
@@ -173,7 +172,7 @@ void ModuleBase_WidgetShapeSelector::updateFocus()
 }
 
 //********************************************************************
-QIntList ModuleBase_WidgetShapeSelector::getShapeTypes() const
+QIntList ModuleBase_WidgetShapeSelector::shapeTypes() const
 {
   QIntList aShapeTypes;
   foreach(QString aType, myShapeTypes) {