Salome HOME
Jenkins compilation correction.
[modules/shaper.git] / src / ModuleBase / ModuleBase_WidgetDoubleValue.cpp
index 9e4a2041e1f19fd0d7b156229f408c0bbbf763ad..3b5b8b455cf0633464499acd892207f194b2d523 100644 (file)
@@ -1,8 +1,22 @@
-// Copyright (C) 2014-20xx CEA/DEN, EDF R&D
-
-// File:        ModuleBase_WidgetDoubleValue.cpp
-// Created:     04 June 2014
-// Author:      Vitaly Smetannikov
+// Copyright (C) 2014-2017  CEA/DEN, EDF R&D
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// See http://www.salome-platform.org/ or
+// email : webmaster.salome@opencascade.com<mailto:webmaster.salome@opencascade.com>
+//
 
 #include <Config_Keywords.h>
 #include <Config_WidgetAPI.h>
@@ -26,7 +40,7 @@
 #include <cfloat>
 
 #ifndef DBL_MAX
-#define DBL_MAX 1.7976931348623158e+308 
+#define DBL_MAX 1.7976931348623158e+308
 #endif
 #ifdef _DEBUG
 #include <iostream>
@@ -41,7 +55,7 @@ ModuleBase_WidgetDoubleValue::ModuleBase_WidgetDoubleValue(QWidget* theParent,
   QFormLayout* aControlLay = new QFormLayout(this);
   ModuleBase_Tools::adjustMargins(aControlLay);
 
-  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())
@@ -86,7 +100,7 @@ ModuleBase_WidgetDoubleValue::ModuleBase_WidgetDoubleValue(QWidget* theParent,
     mySpinBox->setValue(aDefVal);
   }
 
-  QString aTTip = QString::fromStdString(theData->widgetTooltip());
+  QString aTTip = translate(theData->widgetTooltip());
   mySpinBox->setToolTip(aTTip);
   myLabel->setToolTip(aTTip);