]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
Fix a bug with SWIG 1.3.24 - the swigged library should be loaded only once to the...
authorvsr <vsr@opencascade.com>
Wed, 22 Jun 2005 15:23:32 +0000 (15:23 +0000)
committervsr <vsr@opencascade.com>
Wed, 22 Jun 2005 15:23:32 +0000 (15:23 +0000)
src/KERNEL_PY/kernel_shared_modules.py
src/KERNEL_PY/salome_iapp.py

index 76129eecd180c1ed2b300c5c32cb70ec84b7c6c1..b218ef6d31aeaecda9ecfbbb62e27b0b416a02db 100755 (executable)
@@ -10,6 +10,7 @@ from import_hook import register_pattern
 
 register_name("qt")
 register_pattern(lambda(x):x.endswith("_idl"))
+register_pattern(lambda(x):x.endswith("_Swig"))
 
 register_name("omniORB")
 import omniORB
index befa0d075dca54e31a45a7ba1710cfc360cd3d6a..e6ebcaf160733ff34107b4f2aa90d6c86598ec57 100644 (file)
@@ -24,7 +24,6 @@
 #  Module : SALOME
 #  $Header$
 
-from libSALOME_Swig import *
 import salome_ComponentGUI
 
     #--------------------------------------------------------------------------
@@ -54,9 +53,6 @@ def SalomeGUIgetAllSelected(self):
         listSelected.append(self.getSelected(i))
     return listSelected
 
-class SalomeGUI(SALOMEGUI_Swig):
-    getAllSelected = SalomeGUIgetAllSelected
-    
     #--------------------------------------------------------------------------
 
 salome_iapp_initial = 1
@@ -67,8 +63,12 @@ def salome_iapp_init():
 
     if salome_iapp_initial:
         salome_iapp_initial=0
+        import libSALOME_Swig
         
+        class SalomeGUI(libSALOME_Swig.SALOMEGUI_Swig):
+            getAllSelected = SalomeGUIgetAllSelected
+
         # create a SALOMEGUI_Swig instance
         sg = SalomeGUI()
-        IN_SALOME_GUI=sg.hasDesktop()
+        IN_SALOME_GUI = sg.hasDesktop()
     return sg