forked from cia-foundation/TempleOS
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy path01-StartOS.ZC
executable file
·47 lines (35 loc) · 1.21 KB
/
01-StartOS.ZC
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
//This is executed by the System task at boot.
//See $LK,"System Start-up",A="FF:::/Kernel/KMain.ZC,\"StartOS"$.
#help_index "Compiler/Directive"
public extern I8i Option(I64i num, I8i val);
Option(0,0); //(0,0)=EchoOff (0,1)=EchoOn
#include "/Kernel/KernelA.HH"
#include "/Compiler/CompilerA.HH"
#include "/Kernel/KernelB.HH"
#include "/Kernel/KernelC.HH"
#include "/Compiler/CompilerB.HH"
Option(OPTf_WARN_PAREN, ON);
Option(OPTf_WARN_DUP_TYPES, ON);
HashTablePurge(sys_task->hash_table);
#include "/System/MakeSystem"
//Debug("Type 'G;'");
DocTermNew;
WinVert(2, text.rows / 8);
sys_winmgr_task = Spawn(&WinMgrTask, NULL, "Window Manager");
Fs->win_inhibit = WIG_TASK_DEFAULT - WIF_SELF_BORDER - WIF_SELF_GRAB_SCROLL - WIF_SELF_CTRLS;
LBts(&Fs->display_flags, DISPLAYf_CHILDREN_NOT_ON_TOP);
LBts(&Fs->display_flags, DISPLAYf_SHOW);
RegInit;
LBts(&sys_run_level, RLf_REGISTRY);
//if (!ins_reg.registered)
// InsUnreg;
WallPaperInit;
PaletteSetLightEE;
if (DriveIsWritable)
DirMake("/Tmp"); //Good to have a Tmp
Option(OPTf_WARN_PAREN, OFF);
Option(OPTf_WARN_DUP_TYPES, OFF);
LBts(&sys_run_level, RLf_HOME);
#help_index ""
#include "~/02-MakeHome"
//After this file, the System task enters $LK,"server mode",A="HI:Job"$.