Commit 4875f97c authored by John van Groningen's avatar John van Groningen

add CompilerProcessIds to IdeState, make General a boxed record

parent 4ccc492a
......@@ -11,6 +11,7 @@ from PmAbcMagic import :: ABCCache
from PmFileInfo import :: FileInfoCache
import PmEnvironment
import conswin
from PmCleanSystem import ::CompilerProcessIds
:: *General
......@@ -24,6 +25,9 @@ setProject :: !Project !*(PSt *General) -> *PSt *General
appProject :: (Project -> Project) !*(PSt *General) -> *PSt *General
accProject :: (Project -> (.a,Project)) !*(PSt *General) -> (.a,*PSt *General)
getCompilerProcessIds :: !*(PSt *General) -> (!CompilerProcessIds,!*(PSt *General))
setCompilerProcessIds :: !CompilerProcessIds !*(PSt *General) -> *(PSt *General)
:: EditMenuLS l = // local state for the Edit menu
{ zfun :: (PSt l) -> PSt l // undo-function
, xfun :: (PSt l) -> PSt l // cut-function
......
......@@ -5,6 +5,7 @@ import EdState
import PmPath, PmProject, PmPrefs, PmFileInfo
import clipboard, typewin, fbi, PmAbcMagic, errwin
import flextextcontrol, ioutil, UtilStrictLists
from PmCleanSystem import ::CompilerProcessIds,NoCompilerProcessIds
:: InfoDialogInfo =
{pr_info :: !Id // id for info dialog
......@@ -14,8 +15,8 @@ import flextextcontrol, ioutil, UtilStrictLists
,pr_trig :: !Id // id for interrupt trigger
}
:: *General =
{pr_path :: !Pathname // pathname current project
:: *General =
! {pr_path :: !Pathname // pathname current project
,pr_stup :: !Pathname // startupdirectory
,pr_idi :: !InfoDialogInfo
......@@ -48,6 +49,7 @@ import flextextcontrol, ioutil, UtilStrictLists
,print_setup :: !PrintSetup
,project :: !Project
,g_compiler_process_ids :: !CompilerProcessIds
, prefix :: ![String] // prefixes for add/rem prefix
, interact :: Bool
......@@ -76,6 +78,12 @@ accProject f ps
# (prj,ps) = ps!ls.project
# (res,prj) = f prj
= (res,{ps & ls.project = prj})
getCompilerProcessIds :: !*(PSt *General) -> (!CompilerProcessIds,!*(PSt *General))
getCompilerProcessIds ps = accPLoc (\l -> l!g_compiler_process_ids) ps
setCompilerProcessIds :: !CompilerProcessIds !*(PSt *General) -> *(PSt *General)
setCompilerProcessIds compiler_project_ids ps = appPLoc (\l -> {l & g_compiler_process_ids = compiler_project_ids}) ps
::EditMenuLS l =
{ zfun :: (PSt l) -> PSt l
......@@ -271,6 +279,7 @@ iniGeneral
, fi_cache = Just FI_EmptyCache
, print_setup = default_setup
, project = PR_InitProject
, g_compiler_process_ids=NoCompilerProcessIds
, prefix = ["//\t"]
, interact = interact
, logfile = logfile
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment