From 83bea5ad2520932c0ac8e9190402b3f91dcdbd6a Mon Sep 17 00:00:00 2001 From: FellippeHeitor Date: Tue, 19 Jun 2018 22:00:18 -0300 Subject: [PATCH] Makes F5 run detached as default. Running a compiled program in standard "attached" mode had no real use as it had been planned (as once stated by Galleon) to allow future integration of a debug mode that never came to be. It is not practical as is. This change makes F5 (and consequently the Start option in the Run menu) start the program automatically in "detached" mode (equivalent to Ctrl+F5 in previous versions), which means that the resulting binary will be run with SHELL _DONTWAIT instead of simply SHELL, allowing the newly launched process to be independent from the IDE. --- source/ide/ide_methods.bas | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/source/ide/ide_methods.bas b/source/ide/ide_methods.bas index 2d581885e..7d6ab9f72 100644 --- a/source/ide/ide_methods.bas +++ b/source/ide/ide_methods.bas @@ -284,7 +284,7 @@ FUNCTION ide2 (ignore) END IF menu$(m, i) = "-": i = i + 1 - menu$(m, i) = "Start (#Detached) Ctrl+F5": i = i + 1 + 'menu$(m, i) = "Start (#Detached) Ctrl+F5": i = i + 1 IF os$ = "LNX" THEN menu$(m, i) = "Make E#xecutable Only F11": i = i + 1 ELSE @@ -1433,12 +1433,12 @@ FUNCTION ide2 (ignore) END IF END IF - IF KB = KEY_F5 AND KCTRL THEN 'run detached - UseAndroid 0 - idemdetached: - iderunmode = 1 - GOTO idemrunspecial - END IF + 'IF KB = KEY_F5 AND KCTRL THEN 'run detached + ' UseAndroid 0 + ' idemdetached: + ' iderunmode = 1 + ' GOTO idemrunspecial + 'END IF IF KB = KEY_F11 THEN 'make exe only UseAndroid 0 @@ -1450,7 +1450,7 @@ FUNCTION ide2 (ignore) IF KB = KEY_F5 THEN 'Note: F5 or SHIFT+F5 accepted UseAndroid 0 idemrun: - iderunmode = 0 'standard run + iderunmode = 1 'run detached; = 0 'standard run idemrunspecial: IDECompilationRequested = -1 'run program @@ -5215,11 +5215,11 @@ FUNCTION ide2 (ignore) GOTO idemrun END IF - IF menu$(m, s) = "Start (#Detached) Ctrl+F5" THEN - PCOPY 3, 0: SCREEN , , 3, 0: idewait4mous: idewait4alt - UseAndroid 0 - GOTO idemdetached - END IF + 'IF menu$(m, s) = "Start (#Detached) Ctrl+F5" THEN + ' PCOPY 3, 0: SCREEN , , 3, 0: idewait4mous: idewait4alt + ' UseAndroid 0 + ' GOTO idemdetached + 'END IF IF menu$(m, s) = "Make E#XE Only F11" OR menu$(m, s) = "Make E#xecutable Only F11" THEN PCOPY 3, 0: SCREEN , , 3, 0: idewait4mous: idewait4alt