]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Issue #901 - It is possible to define empty name for parameter
authorspo <sergey.pokhodenko@opencascade.com>
Mon, 7 Sep 2015 14:18:10 +0000 (17:18 +0300)
committerspo <sergey.pokhodenko@opencascade.com>
Mon, 7 Sep 2015 14:18:50 +0000 (17:18 +0300)
src/ParametersPlugin/ParametersPlugin_EvalListener.cpp

index 8e826aa1684e5db984c74e331ba6559fa4aa2129..03b4b11996a3d4d1d8830da95dfb2015a8126d97 100644 (file)
@@ -288,7 +288,9 @@ void ParametersPlugin_EvalListener::processObjectRenamedEvent(
   std::shared_ptr<ModelAPI_ObjectRenamedMessage> aMessage =
       std::dynamic_pointer_cast<ModelAPI_ObjectRenamedMessage>(theMessage);
 
-  if (!aMessage.get() || aMessage->oldName().empty() || aMessage->newName().empty())
+  // Empty new name is not available too but it will be rejected by
+  // name validator in isValidAttribute.
+  if (!aMessage.get() || aMessage->oldName().empty())
     return;
 
   // check if the renamed object is a result parameter