1559 cap = self.trUtf8("Run Project") |
1559 cap = self.trUtf8("Run Project") |
1560 else: |
1560 else: |
1561 cap = self.trUtf8("Run Script") |
1561 cap = self.trUtf8("Run Script") |
1562 dlg = StartDialog(cap, self.argvHistory, self.wdHistory, self.envHistory, |
1562 dlg = StartDialog(cap, self.argvHistory, self.wdHistory, self.envHistory, |
1563 self.exceptions, self.ui, 1, |
1563 self.exceptions, self.ui, 1, |
1564 autoClearShell = self.autoClearShell) |
1564 autoClearShell = self.autoClearShell, |
|
1565 autoFork = self.forkAutomatically, |
|
1566 forkChild = self.forkIntoChild) |
1565 if dlg.exec_() == QDialog.Accepted: |
1567 if dlg.exec_() == QDialog.Accepted: |
1566 argv, wd, env, exceptions, clearShell, clearHistories, console = dlg.getData() |
1568 argv, wd, env, exceptions, clearShell, clearHistories, console = dlg.getData() |
|
1569 forkAutomatically, forkIntoChild = dlg.getRunData() |
1567 |
1570 |
1568 if runProject: |
1571 if runProject: |
1569 fn = self.project.getMainScript(1) |
1572 fn = self.project.getMainScript(1) |
1570 if fn is None: |
1573 if fn is None: |
1571 QMessageBox.critical(self.ui, |
1574 QMessageBox.critical(self.ui, |
1624 fn = os.path.join(getConfig('ericDir'), "eric5.py") |
1631 fn = os.path.join(getConfig('ericDir'), "eric5.py") |
1625 |
1632 |
1626 # Ask the client to open the new program. |
1633 # Ask the client to open the new program. |
1627 self.debugServer.remoteRun(fn, argv, wd, env, |
1634 self.debugServer.remoteRun(fn, argv, wd, env, |
1628 autoClearShell = self.autoClearShell, forProject = runProject, |
1635 autoClearShell = self.autoClearShell, forProject = runProject, |
1629 runInConsole = console) |
1636 runInConsole = console, autoFork = forkAutomatically, |
|
1637 forkChild = forkIntoChild) |
1630 |
1638 |
1631 self.stopAct.setEnabled(True) |
1639 self.stopAct.setEnabled(True) |
1632 |
1640 |
1633 def __debugScript(self): |
1641 def __debugScript(self): |
1634 """ |
1642 """ |
1791 if self.lastStartAction in [1, 2]: |
1799 if self.lastStartAction in [1, 2]: |
1792 # Ask the client to debug the new program. |
1800 # Ask the client to debug the new program. |
1793 self.debugServer.remoteLoad(fn, argv, wd, env, |
1801 self.debugServer.remoteLoad(fn, argv, wd, env, |
1794 autoClearShell = self.autoClearShell, tracePython = self.tracePython, |
1802 autoClearShell = self.autoClearShell, tracePython = self.tracePython, |
1795 autoContinue = self.autoContinue, forProject = forProject, |
1803 autoContinue = self.autoContinue, forProject = forProject, |
1796 runInConsole = self.runInConsole) |
1804 runInConsole = self.runInConsole, autoFork = self.forkAutomatically, |
|
1805 forkChild = self.forkIntoChild) |
1797 |
1806 |
1798 # Signal that we have started a debugging session |
1807 # Signal that we have started a debugging session |
1799 self.emit(SIGNAL('debuggingStarted'), fn) |
1808 self.emit(SIGNAL('debuggingStarted'), fn) |
|
1809 |
1800 elif self.lastStartAction in [3, 4]: |
1810 elif self.lastStartAction in [3, 4]: |
1801 # Ask the client to run the new program. |
1811 # Ask the client to run the new program. |
1802 self.debugServer.remoteRun(fn, argv, wd, env, |
1812 self.debugServer.remoteRun(fn, argv, wd, env, |
1803 autoClearShell = self.autoClearShell, forProject = forProject, |
1813 autoClearShell = self.autoClearShell, forProject = forProject, |
1804 runInConsole = self.runInConsole) |
1814 runInConsole = self.runInConsole, autoFork = self.forkAutomatically, |
|
1815 forkChild = self.forkIntoChild) |
|
1816 |
1805 elif self.lastStartAction in [5, 6]: |
1817 elif self.lastStartAction in [5, 6]: |
1806 # Ask the client to coverage run the new program. |
1818 # Ask the client to coverage run the new program. |
1807 self.debugServer.remoteCoverage(fn, argv, wd, env, |
1819 self.debugServer.remoteCoverage(fn, argv, wd, env, |
1808 autoClearShell = self.autoClearShell, erase = self.eraseCoverage, |
1820 autoClearShell = self.autoClearShell, erase = self.eraseCoverage, |
1809 forProject = forProject, runInConsole = self.runInConsole) |
1821 forProject = forProject, runInConsole = self.runInConsole) |
|
1822 |
1810 elif self.lastStartAction in [7, 8]: |
1823 elif self.lastStartAction in [7, 8]: |
1811 # Ask the client to profile run the new program. |
1824 # Ask the client to profile run the new program. |
1812 self.debugServer.remoteProfile(fn, argv, wd, env, |
1825 self.debugServer.remoteProfile(fn, argv, wd, env, |
1813 autoClearShell = self.autoClearShell, erase = self.eraseTimings, |
1826 autoClearShell = self.autoClearShell, erase = self.eraseTimings, |
1814 forProject = forProject, runInConsole = self.runInConsole) |
1827 forProject = forProject, runInConsole = self.runInConsole) |