]> SALOME platform Git repositories - modules/kernel.git/commitdiff
Salome HOME
Improvement PAL13959: improve --splash and --gui options: appy patch from Erwan ADAM
authorvsr <vsr@opencascade.com>
Wed, 22 Nov 2006 08:25:53 +0000 (08:25 +0000)
committervsr <vsr@opencascade.com>
Wed, 22 Nov 2006 08:25:53 +0000 (08:25 +0000)
bin/launchConfigureParser.py
bin/runSalome.py

index 55e9b5568796bf4f5768d952f453c4af1a9c4e25..0f7ce8b4fec8e3dd37787d670d1377944f0fe559 100755 (executable)
@@ -458,16 +458,27 @@ def get_env():
 
     # apply command-line options to the arguments
     BATCHMODE_FORCED = False
+    NO_SPLASH_FORCED = False
     args[script_nam] = []
     for opt in cmd_opts:
         if   opt in [ 'g', gui_nam ] :
             if not BATCHMODE_FORCED: args[gui_nam] = 1
+            if cmd_opts[opt] == ['0']:
+                args["session_gui"] = 0
+                NO_SPLASH_FORCED = True
+                pass
         elif opt in [ 't', terminal_nam ] :
             args[gui_nam] = 0
             args[script_nam] = cmd_opts[opt]
             BATCHMODE_FORCED = True
         elif opt in [ 'z', splash_nam ] :
-            args[splash_nam] = 1
+            if not NO_SPLASH_FORCED:
+                args[splash_nam] = 1
+                if cmd_opts[opt] == ['0']:
+                    args[splash_nam] = 0
+                    pass
+                pass
+            pass
         elif opt in [ 'r', except_nam ] :
             args[except_nam] = 1
         elif opt in [ 'l', logger_nam ] :
index e965e12aa3c9b67cefe6209bd2743a833df4a3d4..c62a0aee97ba029b233072a4a456ecd889518290 100755 (executable)
@@ -467,7 +467,15 @@ class SessionServer(Server):
         if 'supervContainer' in self.args['containers'] or 'supervContainer' in self.args['standalone']:
             self.SCMD2+=['SUPERV']
         if self.args['gui']:
-            self.SCMD2+=['GUI']
+            try:
+                session_gui = self.args['session_gui']
+            except KeyError:
+                session_gui = 1
+                pass
+            if session_gui:
+                self.SCMD2+=['GUI']
+                pass
+            pass
         if self.args['splash'] and self.args['gui']:
             self.SCMD2+=['SPLASH']
         if self.args['noexcepthandler']:
@@ -929,7 +937,7 @@ def main():
     import sys
     if len(sys.argv) == 2:
         if sys.argv[1] == "-nothing":
-            searchFreePort()
+            searchFreePort({})
             import os
             print "port:%s"%(os.environ['NSPORT'])
             import sys