Utilities/Startup.py

changeset 1849
fb1d05e523d3
parent 1775
cbe864be5274
child 2077
68a34718a0ce
child 2303
0ed4ed026c16
--- a/Utilities/Startup.py	Sat May 05 17:07:21 2012 +0200
+++ b/Utilities/Startup.py	Sun May 06 11:21:45 2012 +0200
@@ -203,7 +203,7 @@
 
 
 def simpleAppStartup(argv, appinfo, mwFactory, quitOnLastWindowClosed=True,
-    app=None):
+    app=None, raiseIt=True):
     """
     Module function to start up an application that doesn't need a specialized start up.
     
@@ -220,6 +220,7 @@
     @keyparam quitOnLastWindowClosed flag indicating to quit the application,
         if the last window was closed (boolean)
     @keyparam app reference to the application object (QApplication or None)
+    @keyparam raiseIt flag indicating to raise the generated application window (boolean)
     """
     handleArgs(argv, appinfo)
     if app is None:
@@ -243,6 +244,7 @@
     if quitOnLastWindowClosed:
         app.lastWindowClosed.connect(app.quit)
     w.show()
-    w.raise_()
+    if raiseIt:
+        w.raise_()
     
     return app.exec_()

eric ide

mercurial