From 9f0c57c0c8b45c36fba7e5e3cf8f51bce1ee6fd3 Mon Sep 17 00:00:00 2001 From: vsr Date: Thu, 23 Jun 2005 04:41:34 +0000 Subject: [PATCH] Fix PAL9305 - problem with loading of SALOMEGUI_Swig and other swig libraries on Mandrake 10.1 --- src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py | 4 ++++ src/SALOME_SWIG_WITHOUTIHM/salome_iapp.py | 10 +++++----- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py b/src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py index bcdd46381..b218ef6d3 100755 --- a/src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py +++ b/src/SALOME_SWIG_WITHOUTIHM/kernel_shared_modules.py @@ -10,10 +10,14 @@ 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 +register_name("CosNaming") +import CosNaming + # Modify omniORB to use right sys.modules dictionnary # with multi-interpreter feature # openModule and newModule are functions of omniORB/__init__.py module diff --git a/src/SALOME_SWIG_WITHOUTIHM/salome_iapp.py b/src/SALOME_SWIG_WITHOUTIHM/salome_iapp.py index befa0d075..e6ebcaf16 100644 --- a/src/SALOME_SWIG_WITHOUTIHM/salome_iapp.py +++ b/src/SALOME_SWIG_WITHOUTIHM/salome_iapp.py @@ -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 -- 2.39.2