2021-07-03 05:07:57 +01:00
<!DOCTYPE HTML>
< html >
< head >
< meta http-equiv = "Content-Type" content = "text/html;charset=US-ASCII" >
2021-10-27 08:28:16 +01:00
< meta name = "generator" content = "ZealOS V1.04" >
2021-07-03 05:07:57 +01:00
< style type = "text/css" >
2021-10-08 07:06:11 +01:00
body {background-color:#1f1f1f;}
.cF0{color:#e3e3e3;background-color:#1f1f1f;}
.cF1{color:#4f84a6;background-color:#1f1f1f;}
.cF2{color:#73a255;background-color:#1f1f1f;}
.cF3{color:#297582;background-color:#1f1f1f;}
.cF4{color:#b34f4b;background-color:#1f1f1f;}
.cF5{color:#8a52c3;background-color:#1f1f1f;}
.cF6{color:#b7822f;background-color:#1f1f1f;}
.cF7{color:#444444;background-color:#1f1f1f;}
.cF8{color:#6d6d6d;background-color:#1f1f1f;}
.cF9{color:#94bfde;background-color:#1f1f1f;}
.cFA{color:#a1ce97;background-color:#1f1f1f;}
.cFB{color:#6db4be;background-color:#1f1f1f;}
.cFC{color:#e88e88;background-color:#1f1f1f;}
.cFD{color:#ca94e8;background-color:#1f1f1f;}
.cFE{color:#d4b475;background-color:#1f1f1f;}
.cFF{color:#1f1f1f;background-color:#1f1f1f;}
2021-07-03 05:07:57 +01:00
< / style >
< / head >
< body >
2021-07-05 01:12:38 +01:00
< pre style = "font-family:monospace;font-size:12pt" >
2021-07-26 20:29:49 +01:00
< a name = "l1" > < / a > < span class = cF2 > //This is run in a < / span > < a href = "https://zeal-operating-system.github.io/ZealOS/Kernel/Kernel.PRJ.html#l8" > < span class = cF4 > #exe< / span > < / a > < span class = cF2 > {}.< / span > < span class = cF0 >
2021-07-03 05:07:57 +01:00
< a name = "l2" > < / a >
< a name = "l3" > < / a > < / span > < span class = cF1 > U8< / span > < span class = cF0 > *kernel_config_options = < / span > < span class = cF6 > " MemInit\0" < / span > < span class = cF0 >
2021-07-04 23:11:34 +01:00
< a name = "l4" > < / a > < / span > < span class = cF6 > " HeapInit\0" < / span > < span class = cF0 >
< a name = "l5" > < / a > < / span > < span class = cF6 > " VarInit\0" < / span > < span class = cF0 >
< a name = "l6" > < / a > < / span > < span class = cF6 > " HomeDir\0" < / span > < span class = cF0 >
< a name = "l7" > < / a > < / span > < span class = cF6 > " NoMP\0" < / span > < span class = cF0 >
2021-08-05 04:05:19 +01:00
< a name = "l8" > < / a > < / span > < span class = cF6 > " MountAHCIAuto\0" < / span > < span class = cF0 >
< a name = "l9" > < / a > < / span > < span class = cF6 > " DebugDistro\0" < / span > < span class = cF0 >
< a name = "l10" > < / a > < / span > < span class = cF6 > " Help" < / span > < span class = cF0 > ;
< a name = "l11" > < / a >
< a name = "l12" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_MEM_INIT < / span > < span class = cFE > 0< / span > < span class = cF0 >
< a name = "l13" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_HEAP_INIT < / span > < span class = cFE > 1< / span > < span class = cF0 >
< a name = "l14" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_VAR_INIT < / span > < span class = cFE > 2< / span > < span class = cF0 >
< a name = "l15" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_HOME_DIR < / span > < span class = cFE > 3< / span > < span class = cF0 >
< a name = "l16" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_NO_MP < / span > < span class = cFE > 4< / span > < span class = cF0 >
2021-08-06 06:07:27 +01:00
< a name = "l17" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_MOUNT_AHCI_AUTO < / span > < span class = cFE > 5< / span > < span class = cF0 >
2021-08-05 04:05:19 +01:00
< a name = "l18" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_DEBUG_DISTRO < / span > < span class = cFE > 6< / span > < span class = cF0 >
< a name = "l19" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_OPTIONS_NUM < / span > < span class = cFE > 7< / span > < span class = cF0 >
< a name = "l20" > < / a >
< a name = "l21" > < / a > #< / span > < span class = cF1 > define< / span > < span class = cF0 > CONFIG_HELP < / span > < span class = cFE > 7< / span > < span class = cF0 >
2021-07-03 05:07:57 +01:00
< a name = "l22" > < / a >
2021-08-05 04:05:19 +01:00
< a name = "l23" > < / a > < / span > < span class = cF1 > class< / span > < span class = cF0 > CKConfig
< a name = "l24" > < / a > {
< a name = "l25" > < / a > < / span > < span class = cF1 > U8< / span > < span class = cF0 > *disk_cache_size_exp;
< a name = "l26" > < / a > < / span > < span class = cF9 > CDoc< / span > < span class = cF0 > *add_dev;
< a name = "l27" > < / a > < / span > < span class = cF1 > U8< / span > < span class = cF0 > *debug_distro_file, *debug_distro_start;
< a name = "l28" > < / a > < / span > < span class = cF1 > U8< / span > < span class = cF0 > *home_dir;
< a name = "l29" > < / a > < / span > < span class = cF9 > U16< / span > < span class = cF0 > screen_width, screen_height;
< a name = "l30" > < / a > < / span > < span class = cF1 > Bool< / span > < span class = cF0 > opts[CONFIG_OPTIONS_NUM];
< a name = "l31" > < / a > < / span > < span class = cF1 > U8< / span > < span class = cF0 > mem_init_val, heap_init_val, var_init_val, boot_drive_let, mount_ide_auto_hd_let, mount_ide_auto_cd_let;
< a name = "l32" > < / a > };
< a name = "l33" > < / a >
< a name = "l34" > < / a > < / span > < span class = cF9 > CDoc< / span > < span class = cF0 > *KConfigAddDev(CKConfig *c)
< a name = "l35" > < / a > {
< a name = "l36" > < / a > < / span > < span class = cF9 > I64< / span > < span class = cF0 > ch;
< a name = "l37" > < / a > < / span > < span class = cF9 > CDoc< / span > < span class = cF0 > *doc = < / span > < span class = cF5 > DocNew< / span > < span class = cF0 > ;
< a name = "l38" > < / a >
< a name = "l39" > < / a > < / span > < span class = cF6 > " \n\nIn anticipation of the drives you will define shortly, enter the drive letter\n" < / span > < span class = cF0 >
< a name = "l40" > < / a > < / span > < span class = cF6 > " of the drive with your Home directory. ($PURPLE$< ENTER> $FG$ for current drive) Boot Drive:" < / span > < span class = cF0 > ;
< a name = "l41" > < / a >
< a name = "l42" > < / a > ch = < / span > < span class = cF5 > Letter2Letter< / span > < span class = cF0 > (< / span > < span class = cF5 > CharGet< / span > < span class = cF0 > );
< a name = "l43" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (< / span > < span class = cF6 > 'A'< / span > < span class = cF0 > < = ch < = < / span > < span class = cF6 > 'Z'< / span > < span class = cF0 > )
< a name = "l44" > < / a > c-> boot_drive_let = ch;
< a name = "l45" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l46" > < / a > c-> boot_drive_let = < / span > < span class = cF5 > Drive2Letter< / span > < span class = cF0 > (< / span > < span class = cF5 > Fs< / span > < span class = cF0 > -> cur_dv);
< a name = "l47" > < / a >
< a name = "l48" > < / a > < / span > < span class = cF6 > " \n\n$BK,1$$PURPLE$Mount drives so they will be present when you boot.$FG$$BK,0$\n" < / span > < span class = cF0 > ;
2021-07-03 05:07:57 +01:00
< a name = "l49" > < / a >
2021-08-05 04:05:19 +01:00
< a name = "l50" > < / a > < / span > < span class = cF5 > Mount2< / span > < span class = cF0 > (c-> boot_drive_let, doc, < / span > < span class = cF3 > FALSE< / span > < span class = cF0 > );
2021-07-03 05:07:57 +01:00
< a name = "l51" > < / a >
2021-08-05 04:05:19 +01:00
< a name = "l52" > < / a > < / span > < span class = cF1 > return< / span > < span class = cF0 > doc;
< a name = "l53" > < / a > }
< a name = "l54" > < / a >
< a name = "l55" > < / a > < / span > < span class = cF1 > U0< / span > < span class = cF0 > KConfigOptions(CKConfig *c)
< a name = "l56" > < / a > {
< a name = "l57" > < / a > < / span > < span class = cF9 > I64< / span > < span class = cF0 > i;
< a name = "l58" > < / a > < / span > < span class = cF1 > U8< / span > < span class = cF0 > *st = < / span > < span class = cF3 > NULL< / span > < span class = cF0 > , *st2, *st3;
< a name = "l59" > < / a > < / span > < span class = cF1 > Bool< / span > < span class = cF0 > state;
< a name = "l60" > < / a > < / span > < span class = cF1 > do< / span > < span class = cF0 >
< a name = "l61" > < / a > < / span > < span class = cF7 > {< / span > < span class = cF0 >
< a name = "l62" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (st);
< a name = "l63" > < / a > < / span > < span class = cF1 > for< / span > < span class = cF0 > (i = < / span > < span class = cFE > 0< / span > < span class = cF0 > ; i < CONFIG_OPTIONS_NUM; i++)
< a name = "l64" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (i == CONFIG_HOME_DIR)
< a name = "l65" > < / a > < / span > < span class = cF6 > " $PURPLE$%13tz$FG$:\" %s\" \n" < / span > < span class = cF0 > , i, kernel_config_options, c-> home_dir;
< a name = "l66" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l67" > < / a > < / span > < span class = cF6 > " $PURPLE$%13tz$FG$:%Z\n" < / span > < span class = cF0 > , i, kernel_config_options, c-> opts[i], < / span > < span class = cF6 > " ST_OFF_ON" < / span > < span class = cF0 > ;
< a name = "l68" > < / a > < / span > < span class = cF6 > " \nType '$PURPLE$Help$FG$' for help.\n" < / span > < span class = cF0 > ;
< a name = "l69" > < / a > st = < / span > < span class = cF5 > StrGet< / span > < span class = cF0 > (< / span > < span class = cF6 > " Option ($PURPLE$< ENTER> $FG$ when done):" < / span > < span class = cF0 > , < / span > < span class = cF6 > " " < / span > < span class = cF0 > );
< a name = "l70" > < / a > i = < / span > < span class = cF5 > ListMatch< / span > < span class = cF0 > (st, kernel_config_options, < / span > < span class = cF3 > LMF_IGNORE_CASE< / span > < span class = cF0 > );
< a name = "l71" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (i == CONFIG_HELP)
< a name = "l72" > < / a > < / span > < span class = cF6 > " \n" < / span > < span class = cF0 >
< a name = "l73" > < / a > < / span > < span class = cF6 > " $PURPLE$MemInit$FG$ Initializes memory above 0x100000 " < / span > < span class = cF0 >
Rename abs_addres to abs_address.
Update documentation/comments to rename addr, fun, var, stmt, blk, desc, reg, seg, ptr, dup, clus, val, and bttn, to address, function, variable, statement, block, description, register, segment, pointer, duplicate, cluster, value, and button, respectively.
2021-10-07 02:35:32 +01:00
< a name = "l74" > < / a > < / span > < span class = cF6 > " to a value at boot.\n" < / span > < span class = cF0 >
< a name = "l75" > < / a > < / span > < span class = cF6 > " $PURPLE$HeapInit$FG$ Initializes MAlloc() memory to a value.\n" < / span > < span class = cF0 >
< a name = "l76" > < / a > < / span > < span class = cF6 > " $PURPLE$VarInit$FG$ Initializes global variable memory to a value.\n" < / span > < span class = cF0 >
2021-08-05 04:05:19 +01:00
< a name = "l77" > < / a > < / span > < span class = cF6 > " $PURPLE$HomeDir$FG$ Set home dir.\n" < / span > < span class = cF0 >
< a name = "l78" > < / a > < / span > < span class = cF6 > " $PURPLE$NoMP$FG$ No multicore.\n" < / span > < span class = cF0 >
2021-08-06 06:07:27 +01:00
< a name = "l79" > < / a > < / span > < span class = cF6 > " $PURPLE$MountAHCIAuto$FG$ Auto Mount AHCI drives to 'C' and 'T'.\n" < / span > < span class = cF0 >
< a name = "l80" > < / a > < / span > < span class = cF6 > " $PURPLE$DebugDistro$FG$ Include RAM Drive in Kernel.BIN.\n" < / span > < span class = cF0 >
< a name = "l81" > < / a > < / span > < span class = cF6 > " \n" < / span > < span class = cF0 > ;
< a name = "l82" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l83" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (< / span > < span class = cFE > 0< / span > < span class = cF0 > < = i < CONFIG_OPTIONS_NUM)
< a name = "l84" > < / a > {
< a name = "l85" > < / a > state = c-> opts[i] = !c-> opts[i];
< a name = "l86" > < / a > < / span > < span class = cF1 > switch< / span > < span class = cF0 > (i)
< a name = "l87" > < / a > < / span > < span class = cF7 > {< / span > < span class = cF0 >
< a name = "l88" > < / a > < / span > < span class = cF1 > case< / span > < span class = cF0 > CONFIG_MEM_INIT:
< a name = "l89" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (state)
< a name = "l90" > < / a > c-> mem_init_val = < / span > < span class = cF5 > I64Get< / span > < span class = cF0 > (< / span > < span class = cF6 > " Val (0-255):" < / span > < span class = cF0 > , < / span > < span class = cFE > 255< / span > < span class = cF0 > , < / span > < span class = cFE > 0< / span > < span class = cF0 > , < / span > < span class = cFE > 255< / span > < span class = cF0 > );
< a name = "l91" > < / a > < / span > < span class = cF1 > break< / span > < span class = cF0 > ;
< a name = "l92" > < / a >
< a name = "l93" > < / a > < / span > < span class = cF1 > case< / span > < span class = cF0 > CONFIG_HEAP_INIT:
< a name = "l94" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (state)
< a name = "l95" > < / a > c-> heap_init_val = < / span > < span class = cF5 > I64Get< / span > < span class = cF0 > (< / span > < span class = cF6 > " Val (0-255):" < / span > < span class = cF0 > , < / span > < span class = cFE > 255< / span > < span class = cF0 > , < / span > < span class = cFE > 0< / span > < span class = cF0 > , < / span > < span class = cFE > 255< / span > < span class = cF0 > );
< a name = "l96" > < / a > < / span > < span class = cF1 > break< / span > < span class = cF0 > ;
< a name = "l97" > < / a >
< a name = "l98" > < / a > < / span > < span class = cF1 > case< / span > < span class = cF0 > CONFIG_VAR_INIT:
< a name = "l99" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (state)
< a name = "l100" > < / a > c-> var_init_val = < / span > < span class = cF5 > I64Get< / span > < span class = cF0 > (< / span > < span class = cF6 > " Val (0-255):" < / span > < span class = cF0 > , < / span > < span class = cFE > 255< / span > < span class = cF0 > , < / span > < span class = cFE > 0< / span > < span class = cF0 > , < / span > < span class = cFE > 255< / span > < span class = cF0 > );
< a name = "l101" > < / a > < / span > < span class = cF1 > break< / span > < span class = cF0 > ;
< a name = "l102" > < / a >
< a name = "l103" > < / a > < / span > < span class = cF1 > case< / span > < span class = cF0 > CONFIG_HOME_DIR:
< a name = "l104" > < / a > st2 = < / span > < span class = cF5 > StrGet< / span > < span class = cF0 > (< / span > < span class = cF6 > " Home Dir(\" %s\" ):" < / span > < span class = cF0 > , c-> home_dir);
< a name = "l105" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (!*st2)
< a name = "l106" > < / a > st2 = < / span > < span class = cF5 > StrNew< / span > < span class = cF0 > (< / span > < span class = cF6 > " ::/Home" < / span > < span class = cF0 > );
< a name = "l107" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 > < / span > < span class = cF1 > if< / span > < span class = cF0 > (st2[< / span > < span class = cFE > 1< / span > < span class = cF0 > ] != < / span > < span class = cF6 > ':'< / span > < span class = cF0 > )
< a name = "l108" > < / a > {
< a name = "l109" > < / a > st3 = < / span > < span class = cF5 > MStrPrint< / span > < span class = cF0 > (< / span > < span class = cF6 > " ::%s" < / span > < span class = cF0 > , st2);
< a name = "l110" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (st2);
< a name = "l111" > < / a > st2 = st3;
< a name = "l112" > < / a > }
< a name = "l113" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (c-> home_dir);
< a name = "l114" > < / a > c-> home_dir = st2;
< a name = "l115" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (< / span > < span class = cF5 > StrCompare< / span > < span class = cF7 > (< / span > < span class = cF0 > c-> home_dir, < / span > < span class = cF6 > " ::/Home" < / span > < span class = cF7 > )< / span > < span class = cF0 > )
< a name = "l116" > < / a > c-> opts[i] = < / span > < span class = cF3 > TRUE< / span > < span class = cF0 > ;
< a name = "l117" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l118" > < / a > c-> opts[i] = < / span > < span class = cF3 > FALSE< / span > < span class = cF0 > ;
< a name = "l119" > < / a > < / span > < span class = cF1 > break< / span > < span class = cF0 > ;
< a name = "l120" > < / a >
< a name = "l121" > < / a > < / span > < span class = cF1 > case< / span > < span class = cF0 > CONFIG_MOUNT_AHCI_AUTO:
< a name = "l122" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (state)
< a name = "l123" > < / a > {
< a name = "l124" > < / a > < / span > < span class = cF6 > " First HD Drive Let:" < / span > < span class = cF0 > ;
< a name = "l125" > < / a > c-> mount_ide_auto_hd_let = < / span > < span class = cF5 > Letter2Letter< / span > < span class = cF0 > (< / span > < span class = cF5 > CharGet< / span > < span class = cF0 > );
< a name = "l126" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (!< / span > < span class = cF7 > (< / span > < span class = cF6 > 'A'< / span > < span class = cF0 > < = c-> mount_ide_auto_hd_let < = < / span > < span class = cF6 > 'Z'< / span > < span class = cF7 > )< / span > < span class = cF0 > )
< a name = "l127" > < / a > c-> mount_ide_auto_hd_let = < / span > < span class = cFE > 0< / span > < span class = cF0 > ;
< a name = "l128" > < / a > < / span > < span class = cF6 > '\n'< / span > < span class = cF0 > ;
< a name = "l129" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (c-> mount_ide_auto_hd_let)
< a name = "l130" > < / a > < / span > < span class = cF6 > " First HD Drive:%C\n" < / span > < span class = cF0 > , c-> mount_ide_auto_hd_let;
< a name = "l131" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l132" > < / a > < / span > < span class = cF6 > " First HD Drive:%C\n" < / span > < span class = cF0 > , < / span > < span class = cF6 > 'C'< / span > < span class = cF0 > ;
< a name = "l133" > < / a >
< a name = "l134" > < / a > < / span > < span class = cF6 > " First CD Drive Let:" < / span > < span class = cF0 > ;
< a name = "l135" > < / a > c-> mount_ide_auto_cd_let = < / span > < span class = cF5 > Letter2Letter< / span > < span class = cF0 > (< / span > < span class = cF5 > CharGet< / span > < span class = cF0 > );
< a name = "l136" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (!< / span > < span class = cF7 > (< / span > < span class = cF6 > 'A'< / span > < span class = cF0 > < = c-> mount_ide_auto_cd_let < = < / span > < span class = cF6 > 'Z'< / span > < span class = cF7 > )< / span > < span class = cF0 > )
< a name = "l137" > < / a > c-> mount_ide_auto_cd_let = < / span > < span class = cFE > 0< / span > < span class = cF0 > ;
< a name = "l138" > < / a > < / span > < span class = cF6 > '\n'< / span > < span class = cF0 > ;
< a name = "l139" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (c-> mount_ide_auto_cd_let)
< a name = "l140" > < / a > < / span > < span class = cF6 > " First CD Drive:%C\n" < / span > < span class = cF0 > , c-> mount_ide_auto_cd_let;
< a name = "l141" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l142" > < / a > < / span > < span class = cF6 > " First CD Drive:%C\n" < / span > < span class = cF0 > , < / span > < span class = cF6 > 'T'< / span > < span class = cF0 > ;
< a name = "l143" > < / a > }
< a name = "l144" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l145" > < / a > {
< a name = "l146" > < / a > c-> mount_ide_auto_hd_let = < / span > < span class = cFE > 0< / span > < span class = cF0 > ;
< a name = "l147" > < / a > c-> mount_ide_auto_cd_let = < / span > < span class = cFE > 0< / span > < span class = cF0 > ;
< a name = "l148" > < / a > }
< a name = "l149" > < / a > < / span > < span class = cF1 > break< / span > < span class = cF0 > ;
< a name = "l150" > < / a >
< a name = "l151" > < / a > < / span > < span class = cF1 > case< / span > < span class = cF0 > CONFIG_DEBUG_DISTRO:
< a name = "l152" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (c-> debug_distro_file);
< a name = "l153" > < / a > c-> debug_distro_file = < / span > < span class = cFE > 0< / span > < span class = cF0 > ;
< a name = "l154" > < / a > c-> debug_distro_start = < / span > < span class = cFE > 0< / span > < span class = cF0 > ;
< a name = "l155" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (state)
< a name = "l156" > < / a > {
< a name = "l157" > < / a > c-> debug_distro_file = < / span > < span class = cF5 > StrGet< / span > < span class = cF0 > (< / span > < span class = cF6 > " Debug Distro File:" < / span > < span class = cF0 > );
< a name = "l158" > < / a > c-> debug_distro_start = < / span > < span class = cF5 > I64Get< / span > < span class = cF0 > (< / span > < span class = cF6 > " Debug Distro Start:" < / span > < span class = cF0 > );
< a name = "l159" > < / a > }
< a name = "l160" > < / a > < / span > < span class = cF1 > break< / span > < span class = cF0 > ;
< a name = "l161" > < / a > < / span > < span class = cF7 > }< / span > < span class = cF0 >
< a name = "l162" > < / a > }
< a name = "l163" > < / a > < / span > < span class = cF7 > }< / span > < span class = cF0 >
< a name = "l164" > < / a > < / span > < span class = cF1 > while< / span > < span class = cF0 > (*st);
< a name = "l165" > < / a >
< a name = "l166" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (st);
< a name = "l167" > < / a > }
< a name = "l168" > < / a >
< a name = "l169" > < / a > CKConfig *KConfigNew()
< a name = "l170" > < / a > {
< a name = "l171" > < / a > < / span > < span class = cF9 > I64< / span > < span class = cF0 > resolution_num;
< a name = "l172" > < / a > CKConfig *c = < / span > < span class = cF5 > CAlloc< / span > < span class = cF0 > (< / span > < span class = cF1 > sizeof< / span > < span class = cF7 > (< / span > < span class = cF0 > CKConfig< / span > < span class = cF7 > )< / span > < span class = cF0 > );
< a name = "l173" > < / a >
< a name = "l174" > < / a > c-> add_dev = KConfigAddDev(c);
< a name = "l175" > < / a > c-> home_dir = < / span > < span class = cF5 > StrNew< / span > < span class = cF0 > (< / span > < span class = cF6 > " ::/Home" < / span > < span class = cF0 > );
< a name = "l176" > < / a >
< a name = "l177" > < / a > < / span > < span class = cF5 > VideoRep< / span > < span class = cF0 > (< / span > < span class = cF3 > FALSE< / span > < span class = cF0 > );
< a name = "l178" > < / a > resolution_num = < / span > < span class = cF5 > I64Get< / span > < span class = cF0 > (< / span > < span class = cF6 > " Enter list number of desired resolution, " < / span > < span class = cF0 >
< a name = "l179" > < / a > < / span > < span class = cF6 > " or desired width. ($PURPLE$< ENTER> $FG$ for auto maximum): " < / span > < span class = cF0 > ,, < / span > < span class = cFE > 1< / span > < span class = cF0 > );
< a name = "l180" > < / a > < / span > < span class = cF1 > if< / span > < span class = cF0 > (resolution_num < = < / span > < span class = cF3 > VBE_MODES_NUM< / span > < span class = cF0 > )
< a name = "l181" > < / a > < / span > < span class = cF7 > {< / span > < span class = cF0 >
< a name = "l182" > < / a > c-> screen_width = < / span > < span class = cFB > sys_vbe_modes< / span > < span class = cF0 > [resolution_num - < / span > < span class = cFE > 1< / span > < span class = cF0 > ].width;
< a name = "l183" > < / a > c-> screen_height = < / span > < span class = cFB > sys_vbe_modes< / span > < span class = cF0 > [resolution_num - < / span > < span class = cFE > 1< / span > < span class = cF0 > ].height;
< a name = "l184" > < / a > < / span > < span class = cF7 > }< / span > < span class = cF0 >
< a name = "l185" > < / a > < / span > < span class = cF1 > else< / span > < span class = cF0 >
< a name = "l186" > < / a > < / span > < span class = cF7 > {< / span > < span class = cF0 >
< a name = "l187" > < / a > c-> screen_width = resolution_num;
< a name = "l188" > < / a > c-> screen_height = < / span > < span class = cF5 > I64Get< / span > < span class = cF0 > (< / span > < span class = cF6 > " Enter Height: " < / span > < span class = cF0 > ,, < / span > < span class = cFE > 0< / span > < span class = cF0 > );
< a name = "l189" > < / a > < / span > < span class = cF7 > }< / span > < span class = cF0 >
< a name = "l190" > < / a >
< a name = "l191" > < / a >
< a name = "l192" > < / a > c-> disk_cache_size_exp = < / span > < span class = cF5 > StrGet< / span > < span class = cF0 > (< / span > < span class = cF6 > " \nDisk Cache Size in Bytes, gets rounded-up funny, " < / span > < span class = cF0 >
< a name = "l193" > < / a > < / span > < span class = cF6 > " ($PURPLE$< ENTER> $FG$ will use default.):" < / span > < span class = cF0 > ,
< a name = "l194" > < / a > < / span > < span class = cF6 > " Scale2Mem(0x80000,0x8000000)" < / span > < span class = cF0 > );
< a name = "l195" > < / a > KConfigOptions(c);
< a name = "l196" > < / a >
< a name = "l197" > < / a > < / span > < span class = cF1 > return< / span > < span class = cF0 > c;
< a name = "l198" > < / a > }
< a name = "l199" > < / a >
< a name = "l200" > < / a > < / span > < span class = cF1 > U0< / span > < span class = cF0 > KConfigDel(CKConfig *c)
< a name = "l201" > < / a > {
< a name = "l202" > < / a > < / span > < span class = cF5 > DocDel< / span > < span class = cF0 > (c-> add_dev);
< a name = "l203" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (c-> debug_distro_file);
< a name = "l204" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (c-> home_dir);
< a name = "l205" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (c-> disk_cache_size_exp);
< a name = "l206" > < / a > < / span > < span class = cF5 > Free< / span > < span class = cF0 > (c);
< a name = "l207" > < / a > }
2021-07-03 05:07:57 +01:00
< / span > < / pre > < / body >
< / html >