From: adam Date: Tue, 17 May 2011 09:48:27 +0000 (+0000) Subject: If AAA is in module list and AAA_ROOT_DIR is not defined, trust the user X-Git-Tag: V6_3_0~2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=02298be0052d081c7c7bdfe1ea46f8e25c770f70;p=modules%2Fkernel.git If AAA is in module list and AAA_ROOT_DIR is not defined, trust the user and take account AAA module. If AAA_ROOT_DIR is defined but does not have a SalomeApp.xml in good places, the AAA module is removed from GUI list. --- diff --git a/bin/runSalome.py b/bin/runSalome.py index c6229908b..c604032df 100755 --- a/bin/runSalome.py +++ b/bin/runSalome.py @@ -286,10 +286,14 @@ class SessionServer(Server): list_modules = [] #keep only modules with GUI for m in modules_list: - fr1 = os.path.join(modules_root_dir[m],"share","salome","resources",m.lower(),"SalomeApp.xml") - fr2 = os.path.join(modules_root_dir[m],"share","salome","resources","SalomeApp.xml") - if os.path.exists(fr1) or os.path.exists(fr2): + if m not in modules_root_dir: list_modules.insert(0,m) + else: + fr1 = os.path.join(modules_root_dir[m],"share","salome","resources",m.lower(),"SalomeApp.xml") + fr2 = os.path.join(modules_root_dir[m],"share","salome","resources","SalomeApp.xml") + if os.path.exists(fr1) or os.path.exists(fr2): + list_modules.insert(0,m) + list_modules.reverse() self.SCMD2+=['--modules (%s)' % ":".join(list_modules)] if self.args.has_key('pyscript') and len(self.args['pyscript']) > 0: @@ -505,7 +509,7 @@ def startSalome(args, modules_list, modules_root_dir): # if args["gui"]: - mySessionServ = SessionServer(args,modules_list,modules_root_dir) + mySessionServ = SessionServer(args,args['modules'],modules_root_dir) mySessionServ.setpath(modules_list,modules_root_dir) mySessionServ.run()