]> SALOME platform Git repositories - modules/geom.git/commitdiff
Salome HOME
Small modif due to modif of KERNEL Container modifications
authorAnthony Geay <anthony.geay@edf.fr>
Mon, 22 Feb 2021 15:22:23 +0000 (16:22 +0100)
committerAnthony Geay <anthony.geay@edf.fr>
Mon, 22 Feb 2021 15:22:23 +0000 (16:22 +0100)
src/GEOMGUI/GeometryGUI.cxx
src/GEOM_SWIG/GeomHelper.cxx

index bc39a219f804c172070f7c653df9aeab2c547b98..0b9482dfb77b88d37a3c9996f49e5776e51d2485 100644 (file)
@@ -195,7 +195,7 @@ bool GeometryGUI::IsInGeomComponent( _PTR(SObject) sobject )
 //=======================================================================
 SALOMEDS::Study_var GeometryGUI::getStudyServant()
 {
-  SALOME_NamingService *aNamingService = SalomeApp_Application::namingService();
+  SALOME_NamingService_Abstract *aNamingService = SalomeApp_Application::namingService();
   CORBA::Object_var aStudyObject = aNamingService->Resolve("/Study");
   SALOMEDS::Study_var aStudy = SALOMEDS::Study::_narrow(aStudyObject);
   return aStudy._retn();
index 1b9eaa27fe880ac404b4505318b68fa8a232e9ed..c0601f7ff79286508a72e171008c6b6edfdac21f 100644 (file)
@@ -34,17 +34,12 @@ std::string BuildGEOMInstance()
     PortableServer::POAManager_var pman = poa->the_POAManager();
     CORBA::PolicyList policies;
     policies.length(0);
-    PortableServer::ObjectId_var conId;
-    //
-    {
-        char *argv[4] = {"Container","FactoryServer","GEOM",nullptr};
-        Engines_Container_i *cont = new Engines_Container_i(orb,poa,"FactoryServer",2,argv,false,false);
-        conId = poa->activate_object(cont);
-    }
+    Engines_Container_i *cont( KERNEL::getContainerSA() );
+    PortableServer::ObjectId * conId ( cont->getCORBAId() );
     //
     pman->activate();
     //
-    GEOM_Gen_No_Session_i *servant = new GEOM_Gen_No_Session_i(orb,poa,const_cast<PortableServer::ObjectId*>(&conId.in()),"GEOM_inst_2","GEOM");
+    GEOM_Gen_No_Session_i *servant = new GEOM_Gen_No_Session_i(orb,poa,conId,"GEOM_inst_2","GEOM");
     PortableServer::ObjectId *zeId = servant->getId();
     CORBA::Object_var zeRef = poa->id_to_reference(*zeId);
     char *interfaceName = servant->interfaceName();