]> SALOME platform Git repositories - modules/shaper.git/blobdiff - src/Model/Model_AttributeDouble.cpp
Salome HOME
Issue #718 - Translation with parameters - wrong coordinates
[modules/shaper.git] / src / Model / Model_AttributeDouble.cpp
index 0736eddc0570d7a4611121da979160655e65819f..6128aa892674f49bb26b58b2e20c283df525aaaa 100644 (file)
@@ -15,7 +15,7 @@
 
 using namespace std;
 
-void Model_AttributeDouble::setValue(const double theValue)
+void Model_AttributeDouble::setCalculatedValue(const double theValue)
 {
   if (!myIsInitialized || myReal->Get() != theValue) {
     myReal->Set(theValue);
@@ -23,6 +23,11 @@ void Model_AttributeDouble::setValue(const double theValue)
   }
 }
 
+void Model_AttributeDouble::setValue(const double theValue)
+{
+  setCalculatedValue(text().empty() ? theValue : value());
+}
+
 double Model_AttributeDouble::value()
 {
   return myReal->Get();