Salome HOME
Merge remote branch 'origin/V8_5_asterstudy'
[modules/smesh.git] / src / SMESHGUI / SMESHGUI_HypothesesUtils.cxx
index 3ddfb47dc80d34508d1b253f2ffaef4ea71e4512..7aff8c6ce1b4b281c333e3d19cadf152d9832d07 100644 (file)
@@ -521,7 +521,17 @@ namespace SMESH
       try {
         // load plugin library
         if(MYDEBUG) MESSAGE("Loading client meshers plugin library ...");
-        LibHandle libHandle = LoadLib( aClientLibName.toLatin1().data() );
+#ifdef WIN32
+#ifdef UNICODE
+               LPTSTR path = new TCHAR[aClientLibName.length() + 1];
+               path[aClientLibName.toWCharArray(path)] = '\0';
+#else
+               const char* path = aClientLibName.toUtf8().data();
+#endif
+#else
+               char* path = aClientLibName.toUtf8().data();
+#endif
+        LibHandle libHandle = LoadLib( path );
         if (!libHandle) {
           // report any error, if occurred
           {
@@ -585,7 +595,7 @@ namespace SMESH
     try {
       SMESH::SMESH_Hypothesis_var aHypothesis;
       aHypothesis = SMESHGUI::GetSMESHGen()->CreateHypothesis(aHypType.toLatin1().data(),
-                                                              aServLib.toLatin1().data());
+                                                              aServLib.toUtf8().data());
       if (!aHypothesis->_is_nil()) {
         _PTR(SObject) aHypSObject = SMESH::FindSObject(aHypothesis.in());
         if (aHypSObject) {
@@ -613,7 +623,7 @@ namespace SMESH
     HypothesisData* aHypData = GetHypothesisData(aHypType);
     QString aServLib = aHypData->ServerLibName;
     return SMESHGUI::GetSMESHGen()->IsApplicable( aHypType.toLatin1().data(),
-                                                  aServLib.toLatin1().data(),
+                                                  aServLib.toUtf8().data(),
                                                   theGeomObject,
                                                   toCheckAll);
   }