+//================================================================================
+/*!
+ * \brief Initialize selected objects
+ * \param objects - entries of objects
+ */
+//================================================================================
+
+void StdMeshersGUI_ObjectReferenceParamWdg::SetObjects(SMESH::string_array_var& objects)
+{
+ myObjects.clear();
+ myObjNameLineEdit->setText( "" );
+ myParamValue = "";
+
+ for ( unsigned i = 0; i < objects->length(); ++i )
+ {
+ _PTR(Study) aStudy = SMESH::GetActiveStudyDocument();
+ _PTR(SObject) aSObj = aStudy->FindObjectID(objects[i].in());
+ CORBA::Object_var anObj = SMESH::SObjectToObject(aSObj,aStudy);
+ if ( !CORBA::is_nil( anObj )) {
+ std::string name = aSObj->GetName();
+ QString text = myObjNameLineEdit->text();
+ if ( !text.isEmpty() )
+ text += " ";
+ text += name.c_str();
+ myObjNameLineEdit->setText( text );
+ myObjects.push_back( anObj );
+ myParamValue += " ";
+ myParamValue += objects[i];
+ }
+ }
+}
+