mirror of
https://github.com/minexew/Shrine.git
synced 2026-05-26 05:48:36 +00:00
TempleOSCDV5.02.ISO
This commit is contained in:
Binary file not shown.
+14
-14
@@ -6,34 +6,34 @@ public U8 *DBlk(I64 blk,Bool write=FALSE)
|
||||
//See $LK,"::/Demo/Dsk/DskRaw.HC"$.
|
||||
U8 *buf=MAlloc(BLK_SIZE);
|
||||
|
||||
RBlks(Fs->cur_dv,buf,blk,1);
|
||||
BlkRead(Fs->cur_dv,buf,blk,1);
|
||||
DocD(buf,BLK_SIZE);
|
||||
if (write) {
|
||||
"Edit and press <ESC> to write or <SHIFT-ESC>\n";
|
||||
if (View) {
|
||||
"Write\n";
|
||||
WBlks(Fs->cur_dv,buf,blk,1);
|
||||
BlkWrite(Fs->cur_dv,buf,blk,1);
|
||||
}
|
||||
}
|
||||
return buf;
|
||||
}
|
||||
|
||||
public U8 *DCluster(I64 c,Bool write=FALSE,I64 num=0)
|
||||
{//Dump disk cluster. Optionally, write.
|
||||
//If you set write to TRUE, the cluster will
|
||||
public U8 *DClus(I64 c,Bool write=FALSE,I64 num=0)
|
||||
{//Dump disk clus. Optionally, write.
|
||||
//If you set write to TRUE, the clus will
|
||||
//be written when you press <ESC>.
|
||||
//See $LK,"::/Demo/Dsk/DskRaw.HC"$.
|
||||
//Do $LK,"Dir",A="MN:Dir"$("*",TRUE); to get cluster numbers of files.
|
||||
//Do $LK,"Dir",A="MN:Dir"$("*",TRUE); to get clus numbers of files.
|
||||
U8 *buf=MAlloc(Fs->cur_dv->spc<<BLK_SIZE_BITS);
|
||||
c=ClusterNumNext(Fs->cur_dv,c,num);
|
||||
RClusters(Fs->cur_dv,buf,c,1);
|
||||
"Cluster:%X\n",c;
|
||||
c=ClusNumNext(Fs->cur_dv,c,num);
|
||||
ClusRead(Fs->cur_dv,buf,c,1);
|
||||
"Clus:%X\n",c;
|
||||
DocD(buf,Fs->cur_dv->spc<<BLK_SIZE_BITS);
|
||||
if (write) {
|
||||
"Edit and press <ESC> to write or <SHIFT-ESC>\n";
|
||||
if (View) {
|
||||
"Write\n";
|
||||
WClusters(Fs->cur_dv,buf,c,1);
|
||||
ClusWrite(Fs->cur_dv,buf,c,1);
|
||||
}
|
||||
}
|
||||
return buf;
|
||||
@@ -67,7 +67,7 @@ public Bool Copy(U8 *src_files_find_mask,U8 *dst_files_find_mask=".")
|
||||
CDirContext *dirc;
|
||||
CDirEntry *tmpde,*tmpde1;
|
||||
U8 *st;
|
||||
if (!(tmpde1=FilesFind(src_files_find_mask,FUF_CLUSTER_ORDER)))
|
||||
if (!(tmpde1=FilesFind(src_files_find_mask,FUF_CLUS_ORDER)))
|
||||
return FALSE;
|
||||
if (IsDir(dst_files_find_mask)) {
|
||||
if (dirc=DirContextNew(dst_files_find_mask,TRUE)) {
|
||||
@@ -109,7 +109,7 @@ I64 CopyTree2(CDirEntry *tmpde,I64 src_dir_len,I64 dst_dir_len,U8 *dst_dir)
|
||||
MemCpy(st,dst_dir,dst_dir_len);
|
||||
StrCpy(st+dst_dir_len,tmpde->full_name+src_dir_len);
|
||||
if (tmpde->attr & RS_ATTR_DIR) {
|
||||
MkDir(st,LinkedLstCnt(tmpde->sub));
|
||||
DirMk(st,LinkedLstCnt(tmpde->sub));
|
||||
res+=CopyTree2(tmpde->sub,src_dir_len,dst_dir_len,dst_dir);
|
||||
} else
|
||||
if (CopySingle(tmpde->full_name,st))
|
||||
@@ -140,12 +140,12 @@ public I64 CopyTree(U8 *src_files_find_mask,U8 *dst_files_find_mask,
|
||||
Free(st2);
|
||||
if (dirc=DirContextNew(src_files_find_mask,TRUE,,no_mask)) {
|
||||
tmpde=FilesFind(dirc->mask,FUF_RECURSE);
|
||||
st1=CurDir;
|
||||
st1=DirCur;
|
||||
DirContextDel(dirc);
|
||||
i1=StrLen(st1);
|
||||
if (i1==3) i1--;
|
||||
if (dirc=DirContextNew(dst_files_find_mask,TRUE,TRUE)) {
|
||||
st2=CurDir;
|
||||
st2=DirCur;
|
||||
i2=StrLen(st2);
|
||||
if (i2==3) i2--;
|
||||
res=CopyTree2(tmpde,i1,i2,st2);
|
||||
|
||||
@@ -87,7 +87,7 @@ I64 Size1(CDirEntry *tmpde,I64 *_fuf_flags,I64 round_to)
|
||||
!(tmpde->attr&RS_ATTR_DIR) &&
|
||||
FileAttr(tmpde->name)&RS_ATTR_COMPRESSED) {
|
||||
dv=Let2Drv(*tmpde->full_name);
|
||||
RBlks(dv,buf,Cluster2Blk(dv,tmpde->cluster),1);
|
||||
BlkRead(dv,buf,Clus2Blk(dv,tmpde->clus),1);
|
||||
i=(&buf)(CArcCompress *)->expanded_size;
|
||||
}
|
||||
if (round_to)
|
||||
|
||||
@@ -21,20 +21,20 @@ I64 RedSeaChkDskLst(CDrv *dv,CDirEntry *tmpde1,
|
||||
errs+=RedSeaChkDskLst(dv,tmpde1->sub,bits,bits2,size,bpc);
|
||||
j=(tmpde1->size+bpc-1)/bpc;
|
||||
for (i=0;i<j;i++) {
|
||||
if (i+tmpde1->cluster-dv->data_area>size) {
|
||||
PrintErr("Invalid Cluster:%s Cluster:%X\n",tmpde1->full_name,
|
||||
i+tmpde1->cluster);
|
||||
if (i+tmpde1->clus-dv->data_area>size) {
|
||||
PrintErr("Invalid Clus:%s Clus:%X\n",tmpde1->full_name,
|
||||
i+tmpde1->clus);
|
||||
errs++;
|
||||
break;
|
||||
}
|
||||
if (LBts(bits,i+tmpde1->cluster-dv->data_area)) {
|
||||
PrintErr("Dbl Alloc:%s Cluster:%X\n",tmpde1->full_name,
|
||||
i+tmpde1->cluster);
|
||||
if (LBts(bits,i+tmpde1->clus-dv->data_area)) {
|
||||
PrintErr("Dbl Alloc:%s Clus:%X\n",tmpde1->full_name,
|
||||
i+tmpde1->clus);
|
||||
errs++;
|
||||
}
|
||||
if (!LBtr(bits2,i+tmpde1->cluster-dv->data_area)) {
|
||||
PrintErr("UnAlloc:%s Cluster:%X\n",tmpde1->full_name,
|
||||
i+tmpde1->cluster);
|
||||
if (!LBtr(bits2,i+tmpde1->clus-dv->data_area)) {
|
||||
PrintErr("UnAlloc:%s Clus:%X\n",tmpde1->full_name,
|
||||
i+tmpde1->clus);
|
||||
errs++;
|
||||
}
|
||||
}
|
||||
@@ -59,27 +59,27 @@ I64 RedSeaChkDsk(U8 drv_let,Bool *_fix,Bool *_confirm)
|
||||
bpc=dv->spc<<BLK_SIZE_BITS;
|
||||
bits=CAlloc((size+7)>>3);
|
||||
bits2=CAlloc((size+7)>>3+BLK_SIZE);
|
||||
RBlks(dv,bits2,dv->fat1,((size+7)>>3+BLK_SIZE-1)>>BLK_SIZE_BITS);
|
||||
BlkRead(dv,bits2,dv->fat1,((size+7)>>3+BLK_SIZE-1)>>BLK_SIZE_BITS);
|
||||
|
||||
//Get Root Dir size
|
||||
ptr2=MAlloc(bpc);
|
||||
RBlks(dv,ptr2,dv->root_cluster,1);
|
||||
BlkRead(dv,ptr2,dv->root_clus,1);
|
||||
ptr=ptr2(U8 *)-offset(CDirEntry.start);
|
||||
j=(ptr->size+bpc-1)/bpc;
|
||||
Free(ptr2);
|
||||
|
||||
for (i=0;i<j;i++) {
|
||||
if (i+dv->root_cluster-dv->data_area>size) {
|
||||
PrintErr("Invalid Cluster: RootDir Cluster:%X\n",i+dv->root_cluster);
|
||||
if (i+dv->root_clus-dv->data_area>size) {
|
||||
PrintErr("Invalid Clus: RootDir Clus:%X\n",i+dv->root_clus);
|
||||
errs++;
|
||||
break;
|
||||
}
|
||||
if (LBts(bits,i+dv->root_cluster-dv->data_area)) {
|
||||
PrintErr("Dbl Alloc: RootDir Cluster:%X\n",i+dv->root_cluster);
|
||||
if (LBts(bits,i+dv->root_clus-dv->data_area)) {
|
||||
PrintErr("Dbl Alloc: RootDir Clus:%X\n",i+dv->root_clus);
|
||||
errs++;
|
||||
}
|
||||
if (!LBtr(bits2,i+dv->root_cluster-dv->data_area)) {
|
||||
PrintErr("UnAlloc: RootDir Cluster:%X\n",i+dv->root_cluster);
|
||||
if (!LBtr(bits2,i+dv->root_clus-dv->data_area)) {
|
||||
PrintErr("UnAlloc: RootDir Clus:%X\n",i+dv->root_clus);
|
||||
errs++;
|
||||
}
|
||||
}
|
||||
@@ -88,10 +88,10 @@ I64 RedSeaChkDsk(U8 drv_let,Bool *_fix,Bool *_confirm)
|
||||
bits,bits2,size,bpc);
|
||||
for (i=1;i<size;i++)
|
||||
if (Bt(bits2,i)) {
|
||||
PrintWarn("Shouldn't Alloc Cluster:%0X\n",i+dv->data_area);
|
||||
PrintWarn("Shouldn't Alloc Clus:%0X\n",i+dv->data_area);
|
||||
errs++;
|
||||
if (ChkDskConfirm(_fix,_confirm))
|
||||
RedSeaFreeClusters(dv,i+dv->data_area,1);
|
||||
RedSeaFreeClus(dv,i+dv->data_area,1);
|
||||
}
|
||||
|
||||
Free(files_find_mask);
|
||||
@@ -113,23 +113,23 @@ I64 FAT32ChkDskLst(CDrv *dv,CDirEntry *tmpde1,
|
||||
if (tmpde1->attr & RS_ATTR_DIR && tmpde1->sub)
|
||||
errs+=FAT32ChkDskLst(dv,tmpde1->sub,bits,bits2,size,bpc);
|
||||
i=0;
|
||||
c=tmpde1->cluster;
|
||||
c=tmpde1->clus;
|
||||
while (0<c<0x0FFFFFF8) {
|
||||
if (c>size) {
|
||||
PrintErr("Invalid Cluster:%s Cluster:%X\n",tmpde1->full_name,c);
|
||||
PrintErr("Invalid Clus:%s Clus:%X\n",tmpde1->full_name,c);
|
||||
errs++;
|
||||
break;
|
||||
}
|
||||
if (LBts(bits,c)) {
|
||||
PrintErr("Dbl Alloc:%s Cluster:%X\n",tmpde1->full_name,c);
|
||||
PrintErr("Dbl Alloc:%s Clus:%X\n",tmpde1->full_name,c);
|
||||
errs++;
|
||||
}
|
||||
if (!bits2[c]) {
|
||||
PrintErr("UnAlloc:%s Cluster:%X\n",tmpde1->full_name,c);
|
||||
PrintErr("UnAlloc:%s Clus:%X\n",tmpde1->full_name,c);
|
||||
errs++;
|
||||
} else
|
||||
bits2[c]=0;
|
||||
c=ClusterNumNext(dv,c);
|
||||
c=ClusNumNext(dv,c);
|
||||
i++;
|
||||
}
|
||||
if (!(tmpde1->attr & RS_ATTR_DIR)) {
|
||||
@@ -163,25 +163,25 @@ I64 FAT32ChkDsk(U8 drv_let,Bool *_fix,Bool *_confirm)
|
||||
bpc=dv->spc<<BLK_SIZE_BITS;
|
||||
bits=CAlloc((size+7)>>3);
|
||||
bits2=CAlloc(size*4+BLK_SIZE);
|
||||
RBlks(dv,bits2,dv->fat1,(size*4+BLK_SIZE-1)>>BLK_SIZE_BITS);
|
||||
BlkRead(dv,bits2,dv->fat1,(size*4+BLK_SIZE-1)>>BLK_SIZE_BITS);
|
||||
|
||||
c=dv->root_cluster;
|
||||
c=dv->root_clus;
|
||||
while (0<c<0x0FFFFFF8) {
|
||||
if (c>size) {
|
||||
PrintErr("Invalid Cluster: RootDir Cluster:%X\n",c);
|
||||
PrintErr("Invalid Clus: RootDir Clus:%X\n",c);
|
||||
errs++;
|
||||
break;
|
||||
}
|
||||
if (LBts(bits,c)) {
|
||||
PrintErr("Dbl Alloc: RootDir Cluster:%X\n",c);
|
||||
PrintErr("Dbl Alloc: RootDir Clus:%X\n",c);
|
||||
errs++;
|
||||
}
|
||||
if (!bits2[c]) {
|
||||
PrintErr("UnAlloc: RootDir Cluster:%X\n",c);
|
||||
PrintErr("UnAlloc: RootDir Clus:%X\n",c);
|
||||
errs++;
|
||||
} else
|
||||
bits2[c]=0;
|
||||
c=ClusterNumNext(dv,c);
|
||||
c=ClusNumNext(dv,c);
|
||||
}
|
||||
|
||||
errs+=FAT32ChkDskLst(dv,FilesFind(files_find_mask,FUF_RECURSE),
|
||||
@@ -190,10 +190,10 @@ I64 FAT32ChkDsk(U8 drv_let,Bool *_fix,Bool *_confirm)
|
||||
bits2[1]=0; //See $LK,"FAT32Fmt",A="MN:FAT32Fmt"$()
|
||||
for (i=1;i<size;i++)
|
||||
if (bits2[i]) {
|
||||
PrintWarn("Shouldn't Alloc Cluster:%0X\n",i);
|
||||
PrintWarn("Shouldn't Alloc Clus:%0X\n",i);
|
||||
errs++;
|
||||
if (ChkDskConfirm(_fix,_confirm))
|
||||
FAT32FreeClusters(dv,i);
|
||||
FAT32FreeClus(dv,i);
|
||||
}
|
||||
Free(files_find_mask);
|
||||
Free(bits);
|
||||
@@ -204,7 +204,7 @@ I64 FAT32ChkDsk(U8 drv_let,Bool *_fix,Bool *_confirm)
|
||||
return errs;
|
||||
}
|
||||
|
||||
public I64 ChkDsk(U8 drv_let=0,Bool fix=FALSE,Bool confirm=TRUE)
|
||||
public I64 DskChk(U8 drv_let=0,Bool fix=FALSE,Bool confirm=TRUE)
|
||||
{//Check disk for allocation errors and, optionally, fix.
|
||||
//You probably want to reformat and reinstall.
|
||||
I64 errs=0;
|
||||
@@ -246,7 +246,7 @@ U0 RedSeaDrvView(U8 drv_let=0)
|
||||
try {
|
||||
i=((s+7)>>3+BLK_SIZE-1)>>BLK_SIZE_BITS;
|
||||
bitmap=MAlloc(i<<BLK_SIZE_BITS);
|
||||
RBlks(dv,bitmap,dv->fat1,i);
|
||||
BlkRead(dv,bitmap,dv->fat1,i);
|
||||
i=0;
|
||||
for (y=0;y<GR_HEIGHT-3*FONT_HEIGHT;y++) {
|
||||
if (ScanKey)
|
||||
@@ -288,7 +288,7 @@ U0 FAT32DrvView(U8 drv_let=0)
|
||||
try {
|
||||
i=(s*4+BLK_SIZE-1)>>BLK_SIZE_BITS;
|
||||
bitmap=MAlloc(i<<BLK_SIZE_BITS);
|
||||
RBlks(dv,bitmap,dv->fat1,i);
|
||||
BlkRead(dv,bitmap,dv->fat1,i);
|
||||
i=0;
|
||||
for (y=0;y<GR_HEIGHT-3*FONT_HEIGHT;y++) {
|
||||
if (ScanKey)
|
||||
@@ -394,7 +394,7 @@ I64 RedSeaUnusedDrvSpace(U8 drv_let=0)
|
||||
l=dv->size+dv->drv_offset-dv->data_area;
|
||||
i=((l+7)>>3+BLK_SIZE-1)>>BLK_SIZE_BITS;
|
||||
bitmap=MAlloc(i<<BLK_SIZE_BITS);
|
||||
RBlks(dv,bitmap,dv->fat1,i);
|
||||
BlkRead(dv,bitmap,dv->fat1,i);
|
||||
for (i=0;i<l;i++)
|
||||
if (!Bt(bitmap,i))
|
||||
res++;
|
||||
@@ -412,7 +412,7 @@ I64 FAT32UnusedDrvSpace(U8 drv_let=0)
|
||||
l=(dv->size+dv->spc-1)/dv->spc-(2+dv->data_area-dv->drv_offset);
|
||||
i=(l*4+BLK_SIZE-1)>>BLK_SIZE_BITS;
|
||||
bitmap=MAlloc(i<<BLK_SIZE_BITS);
|
||||
RBlks(dv,bitmap,dv->fat1,i);
|
||||
BlkRead(dv,bitmap,dv->fat1,i);
|
||||
for (i=0;i<l;i++)
|
||||
if (!bitmap[i])
|
||||
res++;
|
||||
@@ -421,7 +421,7 @@ I64 FAT32UnusedDrvSpace(U8 drv_let=0)
|
||||
DrvUnlock(dv);
|
||||
return res*BLK_SIZE*dv->spc;
|
||||
}
|
||||
public I64 UnusedDrvSpace(U8 drv_let=0)
|
||||
public I64 DrvUnused(U8 drv_let=0)
|
||||
{//Returns unused size in bytes.
|
||||
CDrv *dv=Let2Drv(drv_let),*old_dv=Fs->cur_dv;
|
||||
U8 *old_dir=StrNew(Fs->cur_dir);
|
||||
@@ -10,12 +10,12 @@ class CPlannedDrv
|
||||
Bool pri;
|
||||
};
|
||||
|
||||
public I64 PrtDsk(U8 drv_let=0,...)
|
||||
public I64 DskPrt(U8 drv_let=0,...)
|
||||
{/*Partition the disk containing partition drv_let.
|
||||
|
||||
drv_let=0 means add new drive that is not already mounted.
|
||||
|
||||
>PrtDsk('C',0.5,0.25,0.25); //Make three. 50% C, 25% D, 25% E, round-up to blk.
|
||||
>DskPrt('C',0.5,0.25,0.25); //Make three. 50% C, 25% D, 25% E, round-up to blk.
|
||||
|
||||
*/
|
||||
CBlkDev *bd;
|
||||
@@ -145,7 +145,7 @@ U0 FMRebuildDoc(CDoc **_doc,CDirEntry **_head,I64 mode)
|
||||
{
|
||||
CDrv *dv;
|
||||
I64 i;
|
||||
CDoc *doc=*_doc,*doc2=sys_clipboard_doc,*parent_doc;
|
||||
CDoc *doc=*_doc,*doc2=sys_clip_doc,*parent_doc;
|
||||
CFMUncollapsedLst *tmpc=NULL;
|
||||
U8 *cur_entry=NULL,*next_entry=NULL;
|
||||
CDocEntry *doc_ce;
|
||||
@@ -284,7 +284,7 @@ U0 FMMkDir(CDoc *doc)
|
||||
Cd(parent->full_name);
|
||||
if (DocForm(&fn)) {
|
||||
Silent;
|
||||
MkDir(fn.name);
|
||||
DirMk(fn.name);
|
||||
Silent(OFF);
|
||||
}
|
||||
}
|
||||
@@ -293,7 +293,7 @@ U0 FMMkDir(CDoc *doc)
|
||||
Cd(tmpde->full_name);
|
||||
if (DocForm(&fn)) {
|
||||
Silent;
|
||||
MkDir(fn.name);
|
||||
DirMk(fn.name);
|
||||
Silent(OFF);
|
||||
}
|
||||
}
|
||||
@@ -335,7 +335,7 @@ U0 FMChgDsk(CDoc *doc)
|
||||
while (tmpde->parent)
|
||||
tmpde=tmpde->parent;
|
||||
Silent;
|
||||
ChgDsk(*tmpde->full_name);
|
||||
DskChg(*tmpde->full_name);
|
||||
Silent(OFF);
|
||||
}
|
||||
}
|
||||
@@ -439,7 +439,7 @@ U0 FMBurnISO(CDoc *doc)
|
||||
|
||||
U0 FMCopy(CDoc *doc)
|
||||
{
|
||||
CDoc *doc2=sys_clipboard_doc;
|
||||
CDoc *doc2=sys_clip_doc;
|
||||
U8 *st;
|
||||
CDocEntry *doc_ce=doc->cur_entry,*doc_e;
|
||||
CDirEntry *tmpde,*tmpde1=NULL,*tmpde2;
|
||||
@@ -511,7 +511,7 @@ I64 PopUpFMRight(U8 *header=NULL,U8 *footer=NULL)
|
||||
"$$CM+LX,29,0$$$$BT,\"RENAME \",LE=FMR_RENAME$$"
|
||||
"$$CM+LX,1,3 $$$$BT,\"MAKE DIRECTORY \",LE=FMR_MKDIR$$"
|
||||
"$$CM+LX,29,0$$$$BT,\"PLAIN-TEXT EDIT \",LE=FMR_PLAIN$$"
|
||||
"$$CM+LX,1,3 $$$$BT,\"PASTE CLIPBOARD FILES \",LE=FMR_PASTE$$"
|
||||
"$$CM+LX,1,3 $$$$BT,\"PASTE CLIP FILES \",LE=FMR_PASTE$$"
|
||||
"$$CM+LX,29,0$$$$BT,\"CHANGE DISK(MOUNT IT) \",LE=FMR_CHG_DSK$$"
|
||||
"$$CM+LX,1,3 $$$$BT,\"FORMAT \",LE=FMR_FORMAT$$"
|
||||
"$$CM+LX,1,3 $$$$BT,\"MOUNT ISO.C FILE \","
|
||||
@@ -596,7 +596,7 @@ public U8 *FileMgr(I64 mode=FM_NORMAL,CTask *mem_task=NULL)
|
||||
CDirEntry *head=NULL,*tmpde,*tmpde1,*tmpde2;
|
||||
I64 sc,ch,arg1,arg2,msg_code;
|
||||
CDoc *doc=NULL,*old_put_doc=DocPut,*old_display_doc=DocDisplay;
|
||||
U8 *res=NULL,*st,*st2,*old_cur_dir=CurDir;
|
||||
U8 *res=NULL,*st,*st2,*old_cur_dir=DirCur;
|
||||
CDocEntry *doc_ce=NULL,*doc_e;
|
||||
Bool okay;
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
Cd(__DIR__);;
|
||||
#include "ADskA"
|
||||
#include "ADskB"
|
||||
#include "PrtDsk"
|
||||
#include "DskPrt"
|
||||
#include "Mount"
|
||||
#include "ChkDsk"
|
||||
#include "DskChk"
|
||||
#include "FileMgr"
|
||||
Cd("..");;
|
||||
|
||||
@@ -120,9 +120,9 @@ U8 Mount2(U8 boot_drv_let,CDoc *_doc,Bool _caller_is_prtdsk)
|
||||
if ((cnt=ExeDoc(doc)) && whole_drv) {
|
||||
if (_caller_is_prtdsk) {
|
||||
res=drv_let;
|
||||
PrtDsk(drv_let,1.0); //First mount whole drive.
|
||||
DskPrt(drv_let,1.0); //First mount whole drive.
|
||||
} else
|
||||
PrtDsk(drv_let);
|
||||
DskPrt(drv_let);
|
||||
}
|
||||
DocDel(doc);
|
||||
}
|
||||
@@ -136,7 +136,7 @@ U8 Mount2(U8 boot_drv_let,CDoc *_doc,Bool _caller_is_prtdsk)
|
||||
}
|
||||
|
||||
public U8 Mount(Bool caller_is_prtdsk=FALSE)
|
||||
{//Mount drives. Called from $LK,"PrtDsk(Mount)",A="FF:::/Adam/ABlkDev/PrtDsk.HC,Mount("$.
|
||||
{//Mount drives. Called from $LK,"DskPrt(Mount)",A="FF:::/Adam/ABlkDev/DskPrt.HC,Mount("$.
|
||||
return Mount2(0,NULL,caller_is_prtdsk);
|
||||
}
|
||||
|
||||
@@ -147,7 +147,7 @@ public U0 Unmount(U8 drv_let=0)
|
||||
|
||||
public U8 MountFile(U8 *filename)
|
||||
{//Mount ISO.C file.
|
||||
U8 *filename2=DftExt(filename,"ISO.C"),*filename3=FileNameAbs(filename2);
|
||||
U8 *filename2=ExtDft(filename,"ISO.C"),*filename3=FileNameAbs(filename2);
|
||||
CDrv *dv=DrvMakeFreeSlot(DrvNextFreeLet('M')); //First $LK,"BDT_ISO_FILE_READ",A="MN:BDT_ISO_FILE_READ"$
|
||||
CBlkDev *bd=BlkDevNextFreeSlot(dv->drv_let,BDT_ISO_FILE_READ);
|
||||
bd->drv_offset=19<<2+(DVD_BLK_SIZE*2+DVD_BOOT_LOADER_SIZE)/BLK_SIZE;
|
||||
|
||||
+5
-4
@@ -10,16 +10,17 @@ U0 LoadDocDefines()
|
||||
|
||||
//This is cut and replaced when I generate a distro.
|
||||
//See $LK,"DD_TEMPLEOS_LOC",A="FF:::/Demo/AcctExample/TOS/TOSDistro.HC,DD_TEMPLEOS_LOC"$.
|
||||
$TR-C,"LineRep"$
|
||||
$ID,4$DefinePrint("DD_TEMPLEOS_LOC","119,710");
|
||||
DefinePrint("DD_TEMPLEOS_LOC_OFFICIAL","81,944");
|
||||
$ID,-4$
|
||||
|
||||
DefinePrint("DD_KERNEL","%08X",bfh);
|
||||
bfh(I64)+=bfh->file_size-1;
|
||||
DefinePrint("DD_KERNEL_END","%08X",bfh);
|
||||
|
||||
//$LK,"DD_BOOT_HIGH_LOC_DVD",A="FF:::/Adam/Opt/Boot/BootDVD.HC,DD_BOOT_HIGH_LOC_DVD"$
|
||||
|
||||
$TR-C,"LineRep"$
|
||||
$ID,4$DefinePrint("DD_TEMPLEOS_LOC","119,873");
|
||||
DefinePrint("DD_TEMPLEOS_LOC_OFFICIAL","81,990");
|
||||
$ID,-4$
|
||||
DefinePrint("DD_MP_VECT","%08X",MP_VECT_ADDR);
|
||||
DefinePrint("DD_MP_VECT_END","%08X",
|
||||
MP_VECT_ADDR+COREAP_16BIT_INIT_END-COREAP_16BIT_INIT-1);
|
||||
|
||||
+1
-1
@@ -7,7 +7,7 @@ extern U0 ACMisspelledFind(CDoc *doc);
|
||||
extern I64 AdamFile(U8 *filename,Bool warn_ext=TRUE);
|
||||
extern Bool AutoComplete(Bool val=OFF);
|
||||
extern I64 BMPWrite(U8 *filename,CDC *dc,I64 bits=4);
|
||||
extern U0 ClipboardDel();
|
||||
extern U0 ClipDel();
|
||||
extern CCtrl *CtrlFindUnique(CTask *haystack_task,I64 needle_type);
|
||||
extern Bool CtrlInside(CCtrl *c,I64 x,I64 y);
|
||||
extern U8 *DC2Sprite(CDC *tmpb);
|
||||
|
||||
+1
-1
@@ -373,7 +373,7 @@ public U0 PopUpHelpIndex(U8 *idx,CTask *parent=NULL)
|
||||
#help_index "Hash/System"
|
||||
public U0 MapFileLoad(U8 *filename)
|
||||
{//Load map file so we have src line info.
|
||||
U8 *st,*ptr,*name=DftExt(filename,"MAP.Z"),
|
||||
U8 *st,*ptr,*name=ExtDft(filename,"MAP.Z"),
|
||||
*absname=FileNameAbs(name);
|
||||
CDoc *doc=DocRead(name);
|
||||
CDocEntry *doc_e;
|
||||
|
||||
+6
-32
@@ -43,26 +43,14 @@ public Bool RegDft(U8 *path,U8 *val,Bool is_adam_entry=FALSE)
|
||||
public I64 RegExe(U8 *path)
|
||||
{//Execute doc tree branch in registry.
|
||||
RegCache;
|
||||
return DocTreeBranchExe(sys_registry_doc,path);
|
||||
return DocTreeExe(sys_registry_doc,path);
|
||||
}
|
||||
|
||||
public Bool RegWrite(U8 *path,U8 *fmt,...)
|
||||
{//Rewrite doc tree branch in registry.
|
||||
Bool res,unlock_doc;
|
||||
CDocEntry *tree_branch,*start_indent,*end_indent;
|
||||
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||
Bool res;
|
||||
RegCache;
|
||||
unlock_doc=DocLock(sys_registry_doc);
|
||||
if (res=DocTreeFind(sys_registry_doc,path,
|
||||
&tree_branch,&start_indent,&end_indent))
|
||||
DocCut(sys_registry_doc,tree_branch,end_indent);
|
||||
DocTreeMake(sys_registry_doc,path);
|
||||
DocPrint(sys_registry_doc,"%s",buf);
|
||||
if (DrvIsWritable(*sys_registry_doc->filename.name))
|
||||
DocWrite(sys_registry_doc);
|
||||
if (unlock_doc)
|
||||
DocUnlock(sys_registry_doc);
|
||||
Free(buf);
|
||||
res=DocTreeWriteJoin(sys_registry_doc,path,TRUE,fmt,argc,argv);
|
||||
return res;
|
||||
}
|
||||
|
||||
@@ -85,24 +73,10 @@ public I64 RegCnt(U8 *path)
|
||||
}
|
||||
|
||||
public Bool RegAppend(U8 *path,U8 *fmt,...)
|
||||
{//Rewrite doc tree branch in registry.
|
||||
Bool res,unlock_doc;
|
||||
CDocEntry *tree_branch,*start_indent,*end_indent;
|
||||
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||
{//Append to doc tree branch in registry.
|
||||
Bool res;
|
||||
RegCache;
|
||||
unlock_doc=DocLock(sys_registry_doc);
|
||||
if (res=DocTreeFind(sys_registry_doc,path,
|
||||
&tree_branch,&start_indent,&end_indent)) {
|
||||
sys_registry_doc->cur_entry=end_indent;
|
||||
sys_registry_doc->cur_col=sys_registry_doc->cur_entry->min_col;
|
||||
} else
|
||||
DocTreeMake(sys_registry_doc,path);
|
||||
DocPrint(sys_registry_doc,"%s",buf);
|
||||
if (DrvIsWritable(*sys_registry_doc->filename.name))
|
||||
DocWrite(sys_registry_doc);
|
||||
if (unlock_doc)
|
||||
DocUnlock(sys_registry_doc);
|
||||
Free(buf);
|
||||
res=DocTreeAppendJoin(sys_registry_doc,path,TRUE,fmt,argc,argv);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ public U8 *ACDDefGet(U8 *st,I64 def_num=1)
|
||||
if (f=FOpen(ACD_DEF_FILENAME,"r")) {
|
||||
buf=MAlloc(ACD_BLK_SIZE*2+1);
|
||||
buf[ACD_BLK_SIZE*2]=0; //terminate
|
||||
FRBlks(f,buf,tmph->user_data0*ACD_BLK_SIZE/BLK_SIZE,
|
||||
FBlkRead(f,buf,tmph->user_data0*ACD_BLK_SIZE/BLK_SIZE,
|
||||
ACD_BLK_SIZE*2/BLK_SIZE);
|
||||
FClose(f);
|
||||
in_ptr=buf;
|
||||
@@ -55,7 +55,7 @@ public U8 *ACDDefsGet(U8 *st)
|
||||
if (f=FOpen(ACD_DEF_FILENAME,"r")) {
|
||||
buf=MAlloc(ACD_BLK_SIZE*2+1);
|
||||
buf[ACD_BLK_SIZE*2]=0; //terminate
|
||||
FRBlks(f,buf,tmph->user_data0*ACD_BLK_SIZE/BLK_SIZE,
|
||||
FBlkRead(f,buf,tmph->user_data0*ACD_BLK_SIZE/BLK_SIZE,
|
||||
ACD_BLK_SIZE*2/BLK_SIZE);
|
||||
FClose(f);
|
||||
in_ptr=buf;
|
||||
|
||||
@@ -96,7 +96,7 @@ U0 ACMainFileLstTraverse(U8 *files_find_mask)
|
||||
CDirEntry *tmpde,*tmpde1;
|
||||
try {
|
||||
tmpde=tmpde1=FilesFind(files_find_mask,
|
||||
FUF_RECURSE|FUF_JUST_TXT|FUF_JUST_FILES|FUF_CLUSTER_ORDER);
|
||||
FUF_RECURSE|FUF_JUST_TXT|FUF_JUST_FILES|FUF_CLUS_ORDER);
|
||||
while (tmpde) {
|
||||
"%s\n",tmpde->full_name;
|
||||
buf=FileRead(tmpde->full_name);
|
||||
|
||||
@@ -222,8 +222,7 @@ U0 ACTask(I64)
|
||||
LBts(&Fs->display_flags,DISPLAYf_SHOW);
|
||||
WinHorz(51,Fs->win_right);
|
||||
LBts(&Fs->display_flags,DISPLAYf_WIN_ON_TOP);
|
||||
Fs->win_inhibit=WIG_TASK_DFT-WIF_SELF_BORDER
|
||||
-WIF_SELF_MS_L-WIF_SELF_MS_R-WIG_DBL_CLICK;
|
||||
Fs->win_inhibit=WIG_NO_FOCUS_TASK_DFT;
|
||||
Free(ac.cur_word);
|
||||
ac.cur_word=NULL;
|
||||
while (TRUE) {
|
||||
|
||||
+38
-36
@@ -1,19 +1,19 @@
|
||||
#help_index "DolDoc/Clipboard"
|
||||
#help_index "DolDoc/Clip"
|
||||
|
||||
sys_clipboard_doc=DocNew;
|
||||
sys_clip_doc=DocNew;
|
||||
|
||||
public U0 ClipboardDel()
|
||||
{//Delete everything on clipboard.
|
||||
DocRst(sys_clipboard_doc,TRUE);
|
||||
public U0 ClipDel()
|
||||
{//Delete everything on clip.
|
||||
DocRst(sys_clip_doc,TRUE);
|
||||
}
|
||||
|
||||
public U0 EdCopyToClipboard(CDoc *doc)
|
||||
{//Copy $LK,"DOCET_SEL",A="MN:DOCET_SEL"$ flagged entries to clipboard.
|
||||
CDoc *doc2=sys_clipboard_doc;
|
||||
public U0 ClipCopy(CDoc *doc)
|
||||
{//Copy $LK,"DOCET_SEL",A="MN:DOCET_SEL"$ flagged entries to clip.
|
||||
CDoc *doc2=sys_clip_doc;
|
||||
Bool unlock_doc=DocLock(doc),
|
||||
unlock_doc2=DocLock(doc2);
|
||||
CDocEntry *doc_e=doc->head.next,*doc_ne;
|
||||
ClipboardDel;
|
||||
ClipDel;
|
||||
while (doc_e!=doc) {
|
||||
if (doc_e->type & DOCET_SEL) {
|
||||
doc_e->type&=~DOCET_SEL;
|
||||
@@ -30,13 +30,13 @@ public U0 EdCopyToClipboard(CDoc *doc)
|
||||
DocUnlock(doc);
|
||||
}
|
||||
|
||||
public U0 EdCutToClipboard(CDoc *doc)
|
||||
{//Remove sel entries and place on clipboard.
|
||||
CDoc *doc2=sys_clipboard_doc;
|
||||
public U0 ClipCut(CDoc *doc)
|
||||
{//Remove sel entries and place on clip.
|
||||
CDoc *doc2=sys_clip_doc;
|
||||
Bool unlock_doc=DocLock(doc),
|
||||
unlock_doc2=DocLock(doc2);
|
||||
CDocEntry *doc_e=doc->head.next,*doc_e1,*doc_ne,*doc_e2=NULL;
|
||||
ClipboardDel;
|
||||
ClipDel;
|
||||
while (doc_e!=doc) {
|
||||
doc_e1=doc_e->next;
|
||||
if (doc_e->type & DOCET_SEL) {
|
||||
@@ -62,9 +62,9 @@ public U0 EdCutToClipboard(CDoc *doc)
|
||||
DocUnlock(doc);
|
||||
}
|
||||
|
||||
public U0 EdPasteClipboard(CDoc *doc)
|
||||
{//Insert copy of clipboard at insert pt, cur_entry.
|
||||
CDoc *doc2=sys_clipboard_doc;
|
||||
public U0 ClipPaste(CDoc *doc)
|
||||
{//Insert copy of clip at insert pt, cur_entry.
|
||||
CDoc *doc2=sys_clip_doc;
|
||||
Bool unlock_doc=DocLock(doc),
|
||||
unlock_doc2=DocLock(doc2);
|
||||
CDocEntry *doc_ce=doc->cur_entry,*doc_e;
|
||||
@@ -87,17 +87,18 @@ public U0 DocCut(CDoc *doc,CDocEntry *start,CDocEntry *end)
|
||||
{//Del start to end entry, including end points.
|
||||
Bool unlock_doc=DocLock(doc);
|
||||
CDocEntry *doc_e1;
|
||||
while (start!=doc) {
|
||||
doc_e1=start->next;
|
||||
if (start==doc->cur_entry) {
|
||||
doc->cur_entry=start->next;
|
||||
doc->cur_col=doc->cur_entry->min_col;
|
||||
}
|
||||
DocEntryDel(doc,start);
|
||||
if (start==end)
|
||||
break;
|
||||
start=doc_e1;
|
||||
}
|
||||
if (start!=doc && (start->last!=end || end==doc))
|
||||
do {
|
||||
doc_e1=start->next;
|
||||
if (start==doc->cur_entry) {
|
||||
doc->cur_entry=start->next;
|
||||
doc->cur_col=doc->cur_entry->min_col;
|
||||
}
|
||||
DocEntryDel(doc,start);
|
||||
if (start==end)
|
||||
break;
|
||||
start=doc_e1;
|
||||
} while (start!=doc);
|
||||
DocRemSoftNewLines(doc,NULL);
|
||||
if (unlock_doc)
|
||||
DocUnlock(doc);
|
||||
@@ -108,15 +109,16 @@ public CDoc *DocCopy(CDoc *doc,CDocEntry *start,CDocEntry *end)
|
||||
CDoc *doc2=DocNew;
|
||||
Bool unlock_doc=DocLock(doc);
|
||||
CDocEntry *doc_ne;
|
||||
while (start!=doc) {
|
||||
if (!Bt(doldoc.type_flags_data,start->type_u8)) {
|
||||
doc_ne=DocEntryCopy(doc2,start);
|
||||
QueIns(doc_ne,doc2->head.last);
|
||||
}
|
||||
if (start==end)
|
||||
break;
|
||||
start=start->next;
|
||||
}
|
||||
if (start!=doc && (start->last!=end || end==doc))
|
||||
do {
|
||||
if (!Bt(doldoc.type_flags_data,start->type_u8)) {
|
||||
doc_ne=DocEntryCopy(doc2,start);
|
||||
QueIns(doc_ne,doc2->head.last);
|
||||
}
|
||||
if (start==end)
|
||||
break;
|
||||
start=start->next;
|
||||
} while (start!=doc);
|
||||
if (unlock_doc)
|
||||
DocUnlock(doc);
|
||||
return doc2;
|
||||
|
||||
@@ -440,7 +440,7 @@ U0 EdCodeTools2(CDoc *doc,I64 tool_action,Bool beep=TRUE)
|
||||
DocFlagsToggle(doc,DOCF_PLAIN_TEXT);
|
||||
DocWrite(doc);
|
||||
task=Spawn(&SrvCmdLine,NULL,"Srv",,Fs);
|
||||
st2=CurDir;
|
||||
st2=DirCur;
|
||||
st=MStrPrint("Cd(\"%s\");",st2);
|
||||
tmpc=TaskExe(task,Fs,st,1<<JOBf_WAKE_MASTER|1<<JOBf_FOCUS_MASTER);
|
||||
Free(st2);
|
||||
@@ -504,7 +504,7 @@ U0 EdCodeTools2(CDoc *doc,I64 tool_action,Bool beep=TRUE)
|
||||
case EF_REINDENT:
|
||||
start_y=doc->cur_entry->y;
|
||||
EdReplaceTroubleAll(doc,TRUE,FALSE);
|
||||
DocLineNumGoTo(doc,start_y+1);
|
||||
DocGoToLine(doc,start_y+1);
|
||||
if (EdGoToFun(doc,FALSE,FALSE)) {
|
||||
start_y=doc->cur_entry->y;
|
||||
indent=EdRICode(doc);
|
||||
@@ -516,7 +516,7 @@ U0 EdCodeTools2(CDoc *doc,I64 tool_action,Bool beep=TRUE)
|
||||
}
|
||||
DocLock(doc);
|
||||
EdRemFunLeadingSpace(doc);
|
||||
DocLineNumGoTo(doc,start_y+1);
|
||||
DocGoToLine(doc,start_y+1);
|
||||
doc_e=doc->cur_entry;
|
||||
end_y=start_y+indent->total_cnt;
|
||||
while (start_y<=doc_e->y<end_y) {
|
||||
@@ -562,7 +562,7 @@ U0 EdCodeTools2(CDoc *doc,I64 tool_action,Bool beep=TRUE)
|
||||
}
|
||||
start_y=doc->cur_entry->y;
|
||||
EdReplaceTroubleAll(doc,FALSE,FALSE);
|
||||
DocLineNumGoTo(doc,start_y+1);
|
||||
DocGoToLine(doc,start_y+1);
|
||||
break;
|
||||
case EF_RENUM_ASM:
|
||||
if (EdGoToFun(doc,FALSE,TRUE)) {
|
||||
@@ -588,7 +588,7 @@ U0 EdCodeTools2(CDoc *doc,I64 tool_action,Bool beep=TRUE)
|
||||
}
|
||||
|
||||
DocRecalc(doc);
|
||||
DocLineNumGoTo(doc,goto_line_num);
|
||||
DocGoToLine(doc,goto_line_num);
|
||||
|
||||
DocUnlock(doc);
|
||||
if (!unlock)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
#help_index "DolDoc/Editor"
|
||||
|
||||
public Bool DocLineNumGoTo(CDoc *doc,I64 line_num) //one based
|
||||
public Bool DocGoToLine(CDoc *doc,I64 line_num) //one based
|
||||
{//Nearest to specified line num. Move cur_entry & center.
|
||||
Bool res=FALSE,unlock;
|
||||
if (doc) {
|
||||
@@ -30,7 +30,7 @@ U8 *needle,I64 match=1)
|
||||
res=TRUE;
|
||||
doc_e=haystack_doc->head.next;
|
||||
} else {
|
||||
res=DocLineNumGoTo(haystack_doc,start_line_num);
|
||||
res=DocGoToLine(haystack_doc,start_line_num);
|
||||
doc_e=haystack_doc->cur_entry;
|
||||
}
|
||||
if (res) {
|
||||
@@ -580,5 +580,5 @@ U0 EdGoToLine(CDoc *doc)
|
||||
CEdLineGoTo gtl;
|
||||
gtl.line=1;
|
||||
if (DocForm(>l))
|
||||
DocLineNumGoTo(doc,gtl.line);
|
||||
DocGoToLine(doc,gtl.line);
|
||||
}
|
||||
|
||||
@@ -127,7 +127,7 @@ Bool DocFileEd(I64 _type,U8 *filename,
|
||||
if (res || other_found)
|
||||
switch (type) {
|
||||
case LK_FILE_LINE:
|
||||
res=DocLineNumGoTo(doc,*_num);
|
||||
res=DocGoToLine(doc,*_num);
|
||||
break;
|
||||
case LK_FILE_ANCHOR:
|
||||
res=DocAnchorFind(doc,needle_str);
|
||||
|
||||
+10
-16
@@ -8,22 +8,16 @@ public CTask *PopUpViewDoc(CDoc *doc,I64 dof_flags=0)
|
||||
return task;
|
||||
}
|
||||
|
||||
U0 PopUpViewPrintEndCB()
|
||||
{
|
||||
DocDel(FramePtr("ViewStrFrame"));
|
||||
Exit;
|
||||
}
|
||||
|
||||
public CTask *PopUpViewPrint(U8 *fmt,...)
|
||||
{//View Print stmt in PopUp win task.
|
||||
CTask *task;
|
||||
CTask *task=Spawn(&SrvCmdLine,NULL,"View",,Fs);
|
||||
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||
CDoc *doc=DocNew;
|
||||
CDoc *doc=DocNew(,task);
|
||||
DocPrint(doc,buf);
|
||||
Free(buf);
|
||||
task=PopUpViewDoc(doc);
|
||||
FramePtrAdd("ViewStrFrame",doc,task);
|
||||
task->task_end_cb=&PopUpViewPrintEndCB;
|
||||
buf=MStrPrint("DocEd(0x%X);",doc);
|
||||
TaskExe(task,NULL,buf,1<<JOBf_EXIT_ON_COMPLETE|1<<JOBf_FREE_ON_COMPLETE);
|
||||
Free(buf);
|
||||
return task;
|
||||
}
|
||||
|
||||
@@ -34,7 +28,7 @@ public U8 *PopUpPickFile(U8 *dir=NULL)
|
||||
if (dir)
|
||||
st=MStrPrint("Cd(\"%Q\");FileMgr(FM_PICK_FILE,Fs->parent_task);",dir);
|
||||
else {
|
||||
st2=CurDir;
|
||||
st2=DirCur;
|
||||
st=MStrPrint("Cd(\"%Q\");FileMgr(FM_PICK_FILE,Fs->parent_task);",st2);
|
||||
Free(st2);
|
||||
}
|
||||
@@ -49,7 +43,7 @@ public U8 *PopUpPickDir(U8 *dir=NULL)
|
||||
if (dir)
|
||||
st=MStrPrint("Cd(\"%Q\");FileMgr(FM_PICK_DIR,Fs->parent_task);",dir);
|
||||
else {
|
||||
st2=CurDir;
|
||||
st2=DirCur;
|
||||
st=MStrPrint("Cd(\"%Q\");FileMgr(FM_PICK_DIR,Fs->parent_task);",st2);
|
||||
Free(st2);
|
||||
}
|
||||
@@ -270,7 +264,7 @@ public I64 AdamFile(U8 *filename,Bool warn_ext=TRUE)
|
||||
{//Make adam_task execute file.
|
||||
Bool okay=TRUE;
|
||||
U8 *name=FileNameAbs(filename),
|
||||
*name2=DftExt(name,"HC.Z");
|
||||
*name2=ExtDft(name,"HC.Z");
|
||||
I64 res=0;
|
||||
if (warn_ext &&
|
||||
!FilesFindMatch(name2,FILEMASK_JIT) &&
|
||||
@@ -288,7 +282,7 @@ public I64 PopUpFile(U8 *filename,Bool warn_ext=TRUE,
|
||||
{//$LK,"ExeFile2",A="MN:ExeFile2"$() in $LK,"PopUp",A="MN:PopUp"$ task. Cont as User.
|
||||
Bool okay=TRUE;
|
||||
U8 *st,*name=FileNameAbs(filename),
|
||||
*name2=DftExt(name,"HC.Z");
|
||||
*name2=ExtDft(name,"HC.Z");
|
||||
I64 res=0;
|
||||
if (warn_ext &&
|
||||
!FilesFindMatch(name2,FILEMASK_JIT) &&
|
||||
@@ -310,7 +304,7 @@ public I64 PopUpFile(U8 *filename,Bool warn_ext=TRUE,
|
||||
public I64 PopUpRunFile(U8 *filename,I64 ccf_flags=0,...)
|
||||
{//$LK,"ExeFile",A="MN:ExeFile"$() with args using $LK,"LastFun",A="MN:LastFun"$() in $LK,"PopUp",A="MN:PopUp"$ task.
|
||||
U8 *st,*name=FileNameAbs(filename),
|
||||
*name2=DftExt(name,"HC.Z");
|
||||
*name2=ExtDft(name,"HC.Z");
|
||||
I64 res=0;
|
||||
st=MStrPrint(
|
||||
"\"$$$$WW+H,1$$$$\";ExeFile2(\"%s\",0x%X);LastFun(0x%X,0x%X);",
|
||||
|
||||
+12
-12
@@ -182,12 +182,12 @@ public U0 DocPutKey(CDoc *doc,I64 ch=0,I64 sc=0)
|
||||
if (!(sc&SCF_CTRL)) {
|
||||
if (sc&SCF_KEY_DESC) {
|
||||
if (sc&SCF_SHIFT)
|
||||
KeyDescSet("Edit/Cut To Clipboard");
|
||||
KeyDescSet("Edit/Cut To Clip");
|
||||
else
|
||||
KeyDescSet("Char /Delete");
|
||||
} else {
|
||||
if (sc&SCF_SHIFT)
|
||||
EdCutToClipboard(doc);
|
||||
ClipCut(doc);
|
||||
else
|
||||
EdCharDel(doc);
|
||||
}
|
||||
@@ -197,16 +197,16 @@ public U0 DocPutKey(CDoc *doc,I64 ch=0,I64 sc=0)
|
||||
if (sc&(SCF_SHIFT|SCF_CTRL)!=(SCF_SHIFT|SCF_CTRL)) {
|
||||
if (sc&SCF_KEY_DESC) {
|
||||
if (sc&SCF_SHIFT)
|
||||
KeyDescSet("Edit/Paste Clipboard");
|
||||
KeyDescSet("Edit/Paste Clip");
|
||||
else if (sc&SCF_CTRL)
|
||||
KeyDescSet("Edit/Copy to Clipboard");
|
||||
KeyDescSet("Edit/Copy to Clip");
|
||||
else
|
||||
KeyDescSet("Edit/Toggle Overstrike");
|
||||
} else {
|
||||
if (sc&SCF_SHIFT)
|
||||
EdPasteClipboard(doc);
|
||||
ClipPaste(doc);
|
||||
else if (sc&SCF_CTRL)
|
||||
EdCopyToClipboard(doc);
|
||||
ClipCopy(doc);
|
||||
else
|
||||
doc->flags^=DOCF_OVERSTRIKE;
|
||||
}
|
||||
@@ -383,9 +383,9 @@ public U0 DocPutKey(CDoc *doc,I64 ch=0,I64 sc=0)
|
||||
case CH_CTRLC:
|
||||
if (!(sc&SCF_SHIFT)) {
|
||||
if (sc&SCF_KEY_DESC)
|
||||
KeyDescSet("Edit/Copy to Clipboard");
|
||||
KeyDescSet("Edit/Copy to Clip");
|
||||
else
|
||||
EdCopyToClipboard(doc);
|
||||
ClipCopy(doc);
|
||||
}
|
||||
break;
|
||||
case CH_CTRLD:
|
||||
@@ -616,9 +616,9 @@ public U0 DocPutKey(CDoc *doc,I64 ch=0,I64 sc=0)
|
||||
case CH_CTRLV:
|
||||
if (!(sc&SCF_SHIFT)) {
|
||||
if (sc&SCF_KEY_DESC)
|
||||
KeyDescSet("Edit/Paste Clipboard");
|
||||
KeyDescSet("Edit/Paste Clip");
|
||||
else
|
||||
EdPasteClipboard(doc);
|
||||
ClipPaste(doc);
|
||||
}
|
||||
break;
|
||||
case CH_CTRLW:
|
||||
@@ -637,9 +637,9 @@ public U0 DocPutKey(CDoc *doc,I64 ch=0,I64 sc=0)
|
||||
case CH_CTRLX:
|
||||
if (!(sc&SCF_SHIFT)) {
|
||||
if (sc&SCF_KEY_DESC)
|
||||
KeyDescSet("Edit/Cut To Clipboard");
|
||||
KeyDescSet("Edit/Cut To Clip");
|
||||
else
|
||||
EdCutToClipboard(doc);
|
||||
ClipCut(doc);
|
||||
}
|
||||
break;
|
||||
case CH_CTRLY:
|
||||
|
||||
+85
-9
@@ -1,9 +1,9 @@
|
||||
#help_index "DolDoc"
|
||||
#help_index "DolDoc/Tree"
|
||||
|
||||
public Bool DocTreeFind(CDoc *haystack_doc,U8 *needle_path,
|
||||
CDocEntry **_tree_entry=NULL,
|
||||
CDocEntry **_start_indent=NULL, CDocEntry **_end_indent=NULL)
|
||||
{//Find registry-like tree widget start and end.
|
||||
{//Find tree widget start and end.
|
||||
I64 i=0,k=0;
|
||||
U8 *st1=StrNew(needle_path),*st2=MAlloc(StrLen(needle_path)+1);
|
||||
Bool res=FALSE,unlock_doc=DocLock(haystack_doc);
|
||||
@@ -58,8 +58,16 @@ ft_done:
|
||||
return res;
|
||||
}
|
||||
|
||||
public Bool DocTreeFFind(U8 *name,U8 *path)
|
||||
{//Find tree widget in file.
|
||||
CDoc *doc=DocRead(name);
|
||||
Bool res=DocTreeFind(doc,path);
|
||||
DocDel(doc);
|
||||
return res;
|
||||
}
|
||||
|
||||
public Bool DocTreeMake(CDoc *doc,U8 *path)
|
||||
{//Make registry-like tree widget.
|
||||
{//Make tree widget.
|
||||
I64 i=0,j=I64_MIN,k=0;
|
||||
U8 *st1=StrNew(path),
|
||||
*st2=MAlloc(StrLen(path)+1),
|
||||
@@ -113,6 +121,73 @@ mt_done:
|
||||
return res;
|
||||
}
|
||||
|
||||
Bool DocTreeWriteJoin(CDoc *doc,U8 *path,Bool write,U8 *fmt,I64 argc,I64 *argv)
|
||||
{//Rewrite doc tree branch.
|
||||
CDocEntry *tree_branch,*start_indent,*end_indent;
|
||||
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||
Bool res,unlock_doc=DocLock(doc);
|
||||
if (res=DocTreeFind(doc,path,
|
||||
&tree_branch,&start_indent,&end_indent)) {
|
||||
DocCut(doc,start_indent->next,end_indent->last);
|
||||
doc->cur_entry=start_indent->next;
|
||||
doc->cur_col=doc->cur_entry->min_col;
|
||||
} else
|
||||
DocTreeMake(doc,path);
|
||||
DocPrint(doc,"%s",buf);
|
||||
if (write && DrvIsWritable(*doc->filename.name))
|
||||
DocWrite(doc);
|
||||
if (unlock_doc)
|
||||
DocUnlock(doc);
|
||||
Free(buf);
|
||||
return res;
|
||||
}
|
||||
|
||||
Bool DocTreeAppendJoin(CDoc *doc,U8 *path,Bool write,U8 *fmt,I64 argc,I64 *argv)
|
||||
{//Append to doc tree branch.
|
||||
CDocEntry *tree_branch,*start_indent,*end_indent;
|
||||
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||
Bool res,unlock_doc=DocLock(doc);
|
||||
if (res=DocTreeFind(doc,path,
|
||||
&tree_branch,&start_indent,&end_indent)) {
|
||||
doc->cur_entry=end_indent;
|
||||
doc->cur_col=doc->cur_entry->min_col;
|
||||
} else
|
||||
DocTreeMake(doc,path);
|
||||
DocPrint(doc,"%s",buf);
|
||||
if (write && DrvIsWritable(*doc->filename.name))
|
||||
DocWrite(doc);
|
||||
if (unlock_doc)
|
||||
DocUnlock(doc);
|
||||
Free(buf);
|
||||
return res;
|
||||
}
|
||||
|
||||
public Bool DocTreeWrite(CDoc *doc,U8 *path,Bool write=TRUE,U8 *fmt,...)
|
||||
{//Rewrite doc tree branch.
|
||||
return DocTreeWriteJoin(doc,path,write,fmt,argc,argv);
|
||||
}
|
||||
|
||||
public Bool DocTreeAppend(CDoc *doc,U8 *path,Bool write=TRUE,U8 *fmt,...)
|
||||
{//Append to doc tree branch.
|
||||
return DocTreeAppendJoin(doc,path,write,fmt,argc,argv);
|
||||
}
|
||||
|
||||
public Bool DocTreeFWrite(U8 *name,U8 *path,U8 *fmt,...)
|
||||
{//Rewrite doc tree branch in file.
|
||||
CDoc *doc=DocRead(name);
|
||||
Bool res=DocTreeWriteJoin(doc,path,TRUE,fmt,argc,argv);
|
||||
DocDel(doc);
|
||||
return res;
|
||||
}
|
||||
|
||||
public Bool DocTreeFAppend(U8 *name,U8 *path,U8 *fmt,...)
|
||||
{//Append to doc tree branch in file.
|
||||
CDoc *doc=DocRead(name);
|
||||
Bool res=DocTreeAppendJoin(doc,path,TRUE,fmt,argc,argv);
|
||||
DocDel(doc);
|
||||
return res;
|
||||
}
|
||||
|
||||
#help_index "DolDoc/Compiler;Compiler"
|
||||
public I64 ExeDoc(CDoc *doc,I64 ccf_flags=0)
|
||||
{//JIT Compile and execute a document.
|
||||
@@ -141,8 +216,9 @@ public I64 ExeDoc(CDoc *doc,I64 ccf_flags=0)
|
||||
return res;
|
||||
}
|
||||
|
||||
public I64 DocTreeBranchExe(CDoc *doc,U8 *path)
|
||||
{//JIT Compile and execute code in doc tree branch.
|
||||
#help_index "DolDoc/Tree;DolDoc/Compiler;Compiler"
|
||||
public I64 DocTreeExe(CDoc *doc,U8 *path)
|
||||
{//Execute doc tree branch.
|
||||
CDoc *doc2;
|
||||
Bool unlock_doc=DocLock(doc);
|
||||
CDocEntry *tree_branch,*start_indent,*end_indent;
|
||||
@@ -157,11 +233,11 @@ public I64 DocTreeBranchExe(CDoc *doc,U8 *path)
|
||||
return res;
|
||||
}
|
||||
|
||||
public I64 ExeTreeBranch(U8 *registry_file,U8 *path)
|
||||
{//JIT Compile and execute a specified branch in a specified file.
|
||||
public I64 DocTreeFExe(U8 *name,U8 *path)
|
||||
{//Execute doc tree branch in file.
|
||||
I64 res;
|
||||
CDoc *doc=DocRead(registry_file);
|
||||
res=DocTreeBranchExe(doc,path);
|
||||
CDoc *doc=DocRead(name);
|
||||
res=DocTreeExe(doc,path);
|
||||
DocDel(doc);
|
||||
return res;
|
||||
}
|
||||
|
||||
@@ -158,7 +158,7 @@ public U8 *BibleLine2Verse(I64 line,I64 separate_ch=CH_SPACE)
|
||||
}
|
||||
if (0<=--i<cnt) {
|
||||
doc=DocRead(BIBLE_FILENAME,DOCF_PLAIN_TEXT|DOCF_NO_CURSOR);
|
||||
DocLineNumGoTo(doc,line); //one based
|
||||
DocGoToLine(doc,line); //one based
|
||||
doc_e=doc->cur_entry;
|
||||
while (doc_e!=doc && (doc_e->type_u8!=DOCT_TEXT || !*doc_e->tag))
|
||||
doc_e=doc_e->next;
|
||||
@@ -222,7 +222,7 @@ public U0 BookLines(CDoc *doc_out=NULL,I64 start,I64 lines,
|
||||
if (!doc_out) doc_out=DocPut;
|
||||
if (doc_out && FileFind(book_filename)) {
|
||||
doc_in=DocRead(book_filename,DOCF_PLAIN_TEXT|DOCF_NO_CURSOR);
|
||||
DocLineNumGoTo(doc_in,start); //one based
|
||||
DocGoToLine(doc_in,start); //one based
|
||||
doc_e=doc_in->cur_entry;
|
||||
while (lines>0 && doc_e!=doc_in) {
|
||||
if (doc_e->type_u8==DOCT_TEXT)
|
||||
@@ -255,7 +255,7 @@ public U0 BibleVerse(CDoc *doc_out=NULL,U8 *verse,I64 lines)
|
||||
if (i>=0) {
|
||||
i=Str2I64(DefineSub(i,"ST_BIBLE_BOOK_LINES"));
|
||||
doc_in=DocRead(BIBLE_FILENAME,DOCF_PLAIN_TEXT|DOCF_NO_CURSOR);
|
||||
DocLineNumGoTo(doc_in,i); //one based
|
||||
DocGoToLine(doc_in,i); //one based
|
||||
if (*st2) {
|
||||
StrCpy(doc_in->find_replace->find_text,st2);
|
||||
EdFindNext(doc_in);
|
||||
|
||||
@@ -135,6 +135,14 @@ public I64 GodInit(U8 *files_find_mask="/Adam/God/Vocab.DD*",U8 *fu_flags=NULL)
|
||||
return god.num_words;
|
||||
} GodInit;
|
||||
|
||||
public U8 *GodWordStr(I64 bits=17)
|
||||
{//Make God pick a word. $LK+PU,"Holy Spirit Instructions",A="FI:::/Adam/God/HSNotes.DD"$
|
||||
if (god.num_words)
|
||||
return god.words[GodBits(bits)%god.num_words];
|
||||
else
|
||||
return NULL;
|
||||
}
|
||||
|
||||
public U0 GodWord(I64 bits=17,Bool show_num=FALSE)
|
||||
{//Make God pick a word. $LK+PU,"Holy Spirit Instructions",A="FI:::/Adam/God/HSNotes.DD"$
|
||||
I64 i;
|
||||
|
||||
+2
-2
@@ -379,7 +379,7 @@ public CDC *DCLoad(U8 *src,I64 *_size=NULL,CTask *task=NULL)
|
||||
public I64 GRWrite(U8 *filename,CDC *dc,I64 dcsf_flags=DCSF_COMPRESSED)
|
||||
{//TempleOS GR File.
|
||||
I64 size;
|
||||
U8 *st=DftExt(filename,"GR.Z"),
|
||||
U8 *st=ExtDft(filename,"GR.Z"),
|
||||
*src=DCSave(dc,&size,dcsf_flags);
|
||||
FileWrite(st,src,size);
|
||||
Free(st);
|
||||
@@ -390,7 +390,7 @@ public I64 GRWrite(U8 *filename,CDC *dc,I64 dcsf_flags=DCSF_COMPRESSED)
|
||||
public CDC *GRRead(U8 *filename,CTask *task=NULL)
|
||||
{//TempleOS GR File.
|
||||
CDC *dc=NULL;
|
||||
U8 *st=DftExt(filename,"GR.Z"),
|
||||
U8 *st=ExtDft(filename,"GR.Z"),
|
||||
*src=FileRead(st);
|
||||
if (src)
|
||||
dc=DCLoad(src,,task);
|
||||
|
||||
+7
-7
@@ -10,20 +10,20 @@ U0 CtrlAltZ(I64 sc)
|
||||
CtrlAltCBSet('Z',&CtrlAltZ,"Cmd /Zoom In",
|
||||
"Cmd /Zoom Out");
|
||||
|
||||
U0 Scrn2Clipboard(I64)
|
||||
U0 Scrn2Clip(I64)
|
||||
{
|
||||
CDC *dc=DCScrnCapture;
|
||||
U8 *elems=DC2Sprite(dc);
|
||||
Bool unlock_doc=DocLock(sys_clipboard_doc);
|
||||
ClipboardDel;
|
||||
DocSprite(sys_clipboard_doc,elems);
|
||||
Bool unlock_doc=DocLock(sys_clip_doc);
|
||||
ClipDel;
|
||||
DocSprite(sys_clip_doc,elems);
|
||||
if (unlock_doc)
|
||||
DocUnlock(sys_clipboard_doc);
|
||||
DocUnlock(sys_clip_doc);
|
||||
Free(elems);
|
||||
DCDel(dc);
|
||||
}
|
||||
U0 CtrlAltS(I64)
|
||||
{
|
||||
Spawn(&Scrn2Clipboard);
|
||||
Spawn(&Scrn2Clip);
|
||||
}
|
||||
CtrlAltCBSet('S',&CtrlAltS,"Cmd /Scrn Shot to Clipboard");
|
||||
CtrlAltCBSet('S',&CtrlAltS,"Cmd /Scrn Shot to Clip");
|
||||
|
||||
+24
-24
@@ -75,10 +75,10 @@ I64 PopUpSpriteBitMap(CColorROPU32 color,I64 width)
|
||||
"$$MU-UL,\"Flood Fill Not Color\",LE=SPBM_FLOOD_FILL_NOT$$\n"
|
||||
"$$MU-UL,\"PolyLine\",LE=SPBM_POLYLINE$$\n"
|
||||
"$$MU-UL,\"PolyPoint\",LE=SPBM_POLYPT$$\n"
|
||||
"\n$$MU-UL,\"Copy to Clipboard\",LE=SPBM_COPY$$\n"
|
||||
"$$MU-UL,\"Delete to Clipboard\",LE=SPBM_DELETE$$\n"
|
||||
"$$MU-UL,\"Paste Clipboard\",LE=SPBM_PASTE$$\n"
|
||||
"$$MU-UL,\"Paste Transparent Clipboard\",LE=SPBM_PASTE_TRANSPARENT$$\n"
|
||||
"\n$$MU-UL,\"Copy to Clip\",LE=SPBM_COPY$$\n"
|
||||
"$$MU-UL,\"Delete to Clip\",LE=SPBM_DELETE$$\n"
|
||||
"$$MU-UL,\"Paste Clip\",LE=SPBM_PASTE$$\n"
|
||||
"$$MU-UL,\"Paste Transparent Clip\",LE=SPBM_PASTE_TRANSPARENT$$\n"
|
||||
"\n$$MU-UL,\"Save BMP File\",LE=SPBM_SAVE_BMP$$\n"
|
||||
"$$MU-UL,\"Save GR File\",LE=SPBM_SAVE_GRA$$\n"
|
||||
"\n$$MU-UL,\"Undo\",LE=SPBM_UNDO$$\n"
|
||||
@@ -208,7 +208,7 @@ I64 SpriteBitMapEd(CDoc *,CDocEntry *doc_e,CDC *dc,I64 *_xx1,I64 *_yy1,
|
||||
U8 *st=NULL;
|
||||
CEdFileName filename;
|
||||
CDC *img=*_img,
|
||||
*clipboard=NULL,*undo=NULL,*dc2;
|
||||
*clip=NULL,*undo=NULL,*dc2;
|
||||
SettingsPush; //See $LK,"SettingsPush",A="MN:SettingsPush"$
|
||||
|
||||
doc_e->de_flags|=DOCEF_DONT_DRAW;
|
||||
@@ -390,14 +390,14 @@ bm_menu:
|
||||
break;
|
||||
case SPBM_PASTE:
|
||||
case SPBM_PASTE_TRANSPARENT:
|
||||
if (clipboard) {
|
||||
if (clip) {
|
||||
GrBitMapEdPrepPersistentDC(dc,xx1,yy1,img);
|
||||
if (mode==SPBM_PASTE) {
|
||||
clipboard->flags|=DCF_NO_TRANSPARENTS;
|
||||
GrBlot(dc,arg1,arg2,clipboard);
|
||||
clipboard->flags&=~DCF_NO_TRANSPARENTS;
|
||||
clip->flags|=DCF_NO_TRANSPARENTS;
|
||||
GrBlot(dc,arg1,arg2,clip);
|
||||
clip->flags&=~DCF_NO_TRANSPARENTS;
|
||||
} else {
|
||||
dc2=DCCopy(clipboard);
|
||||
dc2=DCCopy(clip);
|
||||
DCColorChg(dc2,bkcolor);
|
||||
GrBlot(dc,arg1,arg2,dc2);
|
||||
DCDel(dc2);
|
||||
@@ -517,14 +517,14 @@ bm_menu:
|
||||
break;
|
||||
case SPBM_PASTE:
|
||||
case SPBM_PASTE_TRANSPARENT:
|
||||
if (clipboard) {
|
||||
if (clip) {
|
||||
GrBitMapEdPrepPersistentDC(dc,xx1,yy1,img);
|
||||
if (mode==SPBM_PASTE) {
|
||||
clipboard->flags|=DCF_NO_TRANSPARENTS;
|
||||
GrBlot(dc,arg1,arg2,clipboard);
|
||||
clipboard->flags&=~DCF_NO_TRANSPARENTS;
|
||||
clip->flags|=DCF_NO_TRANSPARENTS;
|
||||
GrBlot(dc,arg1,arg2,clip);
|
||||
clip->flags&=~DCF_NO_TRANSPARENTS;
|
||||
} else {
|
||||
dc2=DCCopy(clipboard);
|
||||
dc2=DCCopy(clip);
|
||||
DCColorChg(dc2,bkcolor);
|
||||
GrBlot(dc,arg1,arg2,dc2);
|
||||
DCDel(dc2);
|
||||
@@ -611,9 +611,9 @@ bm_menu:
|
||||
y11=arg2;
|
||||
y22=y1;
|
||||
}
|
||||
DCDel(clipboard);
|
||||
clipboard=DCExt(img,x11-xx1,y11-yy1,x22-xx1,y22-yy1);
|
||||
clipboard->bkcolor=bkcolor;
|
||||
DCDel(clip);
|
||||
clip=DCExt(img,x11-xx1,y11-yy1,x22-xx1,y22-yy1);
|
||||
clip->bkcolor=bkcolor;
|
||||
if (mode==SPBM_DELETE) {
|
||||
img->color=bkcolor;
|
||||
GrRect(img,x11-xx1,y11-yy1,x22-x11+1,y22-y11+1);
|
||||
@@ -629,14 +629,14 @@ bm_menu:
|
||||
break;
|
||||
case SPBM_PASTE:
|
||||
case SPBM_PASTE_TRANSPARENT:
|
||||
if (clipboard) {
|
||||
if (clip) {
|
||||
GrBitMapEdPrepPersistentDC(dc,xx1,yy1,img);
|
||||
if (mode==SPBM_PASTE) {
|
||||
clipboard->flags|=DCF_NO_TRANSPARENTS;
|
||||
GrBlot(img,arg1-xx1,arg2-yy1,clipboard);
|
||||
clipboard->flags&=~DCF_NO_TRANSPARENTS;
|
||||
clip->flags|=DCF_NO_TRANSPARENTS;
|
||||
GrBlot(img,arg1-xx1,arg2-yy1,clip);
|
||||
clip->flags&=~DCF_NO_TRANSPARENTS;
|
||||
} else {
|
||||
dc2=DCCopy(clipboard);
|
||||
dc2=DCCopy(clip);
|
||||
DCColorChg(dc2,bkcolor);
|
||||
GrBlot(img,arg1-xx1,arg2-yy1,dc2);
|
||||
DCDel(dc2);
|
||||
@@ -665,7 +665,7 @@ bm_menu:
|
||||
bm_key_up_done:
|
||||
GetMsg(,,1<<MSG_KEY_UP);
|
||||
bm_done:
|
||||
DCDel(clipboard);
|
||||
DCDel(clip);
|
||||
DCDel(undo);
|
||||
Free(st);
|
||||
DCFill(dc);
|
||||
|
||||
+9
-9
@@ -724,7 +724,7 @@ Bool SpriteEdText(CSprite **_head,I64 *_cur_elem_num)
|
||||
#define SPED_SET_ORIGIN 10
|
||||
#define SPED_SHIFT_SUB_ORIGIN 11
|
||||
#define SPED_TEXT_ED 12
|
||||
#define SPED_INS_CLIPBOARD 13
|
||||
#define SPED_INS_CLIP 13
|
||||
#define SPED_MAIN_MENU 14
|
||||
#define SPED_EXIT 15
|
||||
|
||||
@@ -733,7 +733,7 @@ U0 GrInit3()
|
||||
DefineLstLoad("ST_SPRITE_ED_MENU","Select/Unselect All\0 \0Select\0"
|
||||
"Select Rects\0Unselect\0Unselect Rects\0Shift Points\0Shift Rects\0"
|
||||
"Shift Selected\0Transform Selected\0Set Origin\0"
|
||||
"Insert Shift SubOrigin\0Edit as Text\0Insert Clipboard\0Main Menu\0");
|
||||
"Insert Shift SubOrigin\0Edit as Text\0Insert Clip\0Main Menu\0");
|
||||
}
|
||||
GrInit3;
|
||||
|
||||
@@ -757,7 +757,7 @@ I64 PopUpSpriteEd(CSprite **_head,I64 *_cur_elem_num)
|
||||
"$$MU-UL,\"Set Origin\",LE=SPED_SET_ORIGIN$$\n"
|
||||
"$$MU-UL,\"Insert Shift SubOrigin\",LE=SPED_SHIFT_SUB_ORIGIN$$\n\n"
|
||||
"$$MU-UL,\"Edit as Text\",LE=SPED_TEXT_ED$$\n"
|
||||
"$$MU-UL,\"Insert Clipboard Sprite's\",LE=SPED_INS_CLIPBOARD$$\n\n"
|
||||
"$$MU-UL,\"Insert Clip Sprite's\",LE=SPED_INS_CLIP$$\n\n"
|
||||
"$$PURPLE$$$$MU-UL,\"+] Sprite Main Menu\",LE=SPED_MAIN_MENU$$$$LTBLUE$$\n"
|
||||
"$$MU-UL,\"Exit Sprite\",LE=SPED_EXIT$$\n"
|
||||
"$$MU-UL,\"Abort Sprite\",LE=DOCM_CANCEL$$");
|
||||
@@ -1218,17 +1218,17 @@ I64 SpriteEd(CDoc *doc,CDocEntry *doc_ce,I64 x,I64 y,
|
||||
} while (msg_code!=MSG_MS_L_UP);
|
||||
*_cur_elem_num+=1;
|
||||
break;
|
||||
case SPED_INS_CLIPBOARD:
|
||||
RegOneTimePopUp(ARf_CSPRITE_INS_CLIPBOARD,
|
||||
case SPED_INS_CLIP:
|
||||
RegOneTimePopUp(ARf_CSPRITE_INS_CLIP,
|
||||
"You will probably want to shift around\n"
|
||||
"the location of element groups. Use\n"
|
||||
"'Insert shift sub-origin' after picking the\n"
|
||||
"element to insert before. Or,\n"
|
||||
"use 'shift points'.\n");
|
||||
insert_pt=SpriteSetSettings(,*_head,*_cur_elem_num);
|
||||
unlock=DocLock(sys_clipboard_doc);
|
||||
doc_e2=sys_clipboard_doc->head.next;
|
||||
while (doc_e2!=sys_clipboard_doc) {
|
||||
unlock=DocLock(sys_clip_doc);
|
||||
doc_e2=sys_clip_doc->head.next;
|
||||
while (doc_e2!=sys_clip_doc) {
|
||||
if (doc_e2->type_u8==DOCT_SPRITE) {
|
||||
head2=Sprite2SpriteQue(doc_e2->bin_data->data);
|
||||
if (head2->next!=head2) {
|
||||
@@ -1249,7 +1249,7 @@ I64 SpriteEd(CDoc *doc,CDocEntry *doc_ce,I64 x,I64 y,
|
||||
doc_e2=doc_e2->next;
|
||||
}
|
||||
if (unlock)
|
||||
DocUnlock(sys_clipboard_doc);
|
||||
DocUnlock(sys_clip_doc);
|
||||
SpriteEdUpdate(doc,doc_ce,*_head);
|
||||
break;
|
||||
case SPED_TEXT_ED:
|
||||
|
||||
+33
-33
@@ -588,33 +588,33 @@ U0 MeshCursorW(CMeshFrame *e,CTask *task,I64 *_x,I64 *_y,I64 *_z)
|
||||
*_x=x; *_y=y; *_z=z;
|
||||
}
|
||||
|
||||
CMeshEdVertex sys_clipboard_vertex_head;
|
||||
CMeshEdTri sys_clipboard_tri_head;
|
||||
CMeshEdVertex sys_clip_vertex_head;
|
||||
CMeshEdTri sys_clip_tri_head;
|
||||
|
||||
U0 MeshClipboardInit()
|
||||
U0 MeshClipInit()
|
||||
{
|
||||
QueInit(&sys_clipboard_vertex_head);
|
||||
QueInit(&sys_clipboard_tri_head);
|
||||
QueInit(&sys_clip_vertex_head);
|
||||
QueInit(&sys_clip_tri_head);
|
||||
}
|
||||
|
||||
U0 MeshClipboardRst()
|
||||
U0 MeshClipRst()
|
||||
{
|
||||
QueDel(&sys_clipboard_vertex_head,TRUE);
|
||||
QueDel(&sys_clipboard_tri_head,TRUE);
|
||||
MeshClipboardInit;
|
||||
QueDel(&sys_clip_vertex_head,TRUE);
|
||||
QueDel(&sys_clip_tri_head,TRUE);
|
||||
MeshClipInit;
|
||||
}
|
||||
|
||||
U0 MeshClipboardCopy(CMeshFrame *e)
|
||||
U0 MeshClipCopy(CMeshFrame *e)
|
||||
{
|
||||
CMeshEdVertex *tmpv=e->vertex_head.next,*tmpv2;
|
||||
CMeshEdTri *tmpt=e->tri_head.next,*tmpt2;
|
||||
|
||||
MeshClipboardRst;
|
||||
MeshClipRst;
|
||||
while (tmpv!=&e->vertex_head) {
|
||||
if (tmpv->flags&VF_SEL) {
|
||||
tmpv->copy=tmpv2=ACAlloc(sizeof(CMeshEdVertex));
|
||||
MemCpy(&tmpv2->p,&tmpv->p,sizeof(CD3I32));
|
||||
QueIns(tmpv2,sys_clipboard_vertex_head.last);
|
||||
QueIns(tmpv2,sys_clip_vertex_head.last);
|
||||
tmpv->flags|=VF_COPIED;
|
||||
tmpv->flags&=~VF_SEL;
|
||||
} else {
|
||||
@@ -631,7 +631,7 @@ U0 MeshClipboardCopy(CMeshFrame *e)
|
||||
tmpt2->t[1]=tmpt->t[1]->copy;
|
||||
tmpt2->t[2]=tmpt->t[2]->copy;
|
||||
tmpt2->mt.color=tmpt->mt.color;
|
||||
QueIns(tmpt2,sys_clipboard_tri_head.last);
|
||||
QueIns(tmpt2,sys_clip_tri_head.last);
|
||||
tmpt->flags|=TF_COPIED;
|
||||
tmpt->flags&=~TF_SEL;
|
||||
} else
|
||||
@@ -640,11 +640,11 @@ U0 MeshClipboardCopy(CMeshFrame *e)
|
||||
}
|
||||
}
|
||||
|
||||
U0 MeshClipboardCut(CMeshFrame *e)
|
||||
U0 MeshClipCut(CMeshFrame *e)
|
||||
{
|
||||
CMeshEdVertex *tmpv=e->vertex_head.next,*tmpv1;
|
||||
CMeshEdTri *tmpt=e->tri_head.next,*tmpt1;
|
||||
MeshClipboardCopy(e);
|
||||
MeshClipCopy(e);
|
||||
while (tmpt!=&e->tri_head) {
|
||||
tmpt1=tmpt->next;
|
||||
if (tmpt->flags&TF_COPIED)
|
||||
@@ -659,8 +659,8 @@ U0 MeshClipboardCut(CMeshFrame *e)
|
||||
}
|
||||
}
|
||||
|
||||
U0 MeshClipboardDel(CMeshFrame *e)
|
||||
{//Technically not clipboard
|
||||
U0 MeshClipDel(CMeshFrame *e)
|
||||
{//Technically not clip
|
||||
CMeshEdVertex *tmpv=e->vertex_head.next,*tmpv1;
|
||||
CMeshEdTri *tmpt=e->tri_head.next,*tmpt1;
|
||||
while (tmpt!=&e->tri_head) {
|
||||
@@ -677,14 +677,14 @@ U0 MeshClipboardDel(CMeshFrame *e)
|
||||
}
|
||||
}
|
||||
|
||||
U0 MeshClipboardPaste(CMeshFrame *e)
|
||||
U0 MeshClipPaste(CMeshFrame *e)
|
||||
{
|
||||
CMeshEdVertex *tmpv2=sys_clipboard_vertex_head.next,*tmpv;
|
||||
CMeshEdTri *tmpt2=sys_clipboard_tri_head.next,*tmpt;
|
||||
CMeshEdVertex *tmpv2=sys_clip_vertex_head.next,*tmpv;
|
||||
CMeshEdTri *tmpt2=sys_clip_tri_head.next,*tmpt;
|
||||
|
||||
MeshVertexSelAll(e,FALSE);
|
||||
MeshTriSelAll(e,FALSE);
|
||||
while (tmpv2!=&sys_clipboard_vertex_head) {
|
||||
while (tmpv2!=&sys_clip_vertex_head) {
|
||||
tmpv2->copy=tmpv=CAlloc(sizeof(CMeshEdVertex));
|
||||
MemCpy(&tmpv->p,&tmpv2->p,sizeof(CD3I32));
|
||||
QueIns(tmpv,e->vertex_head.last);
|
||||
@@ -692,7 +692,7 @@ U0 MeshClipboardPaste(CMeshFrame *e)
|
||||
tmpv2=tmpv2->next;
|
||||
}
|
||||
|
||||
while (tmpt2!=&sys_clipboard_tri_head) {
|
||||
while (tmpt2!=&sys_clip_tri_head) {
|
||||
tmpt=MeshTriNew(e,tmpt2->mt.color,tmpt2->t[0]->copy,
|
||||
tmpt2->t[1]->copy,tmpt2->t[2]->copy);
|
||||
tmpt->flags|=TF_SEL;
|
||||
@@ -700,7 +700,7 @@ U0 MeshClipboardPaste(CMeshFrame *e)
|
||||
}
|
||||
}
|
||||
|
||||
MeshClipboardInit;
|
||||
MeshClipInit;
|
||||
|
||||
U0 DrawIt(CTask *task,CDC *dc)
|
||||
{
|
||||
@@ -1088,10 +1088,10 @@ me_restart:
|
||||
switch (arg2.u8[0]) {
|
||||
case SC_DELETE:
|
||||
if (arg2&SCF_SHIFT)
|
||||
goto me_clipboard_cut;
|
||||
goto me_clip_cut;
|
||||
else {
|
||||
if (MeshSelCnt(&e))
|
||||
MeshClipboardDel(&e);
|
||||
MeshClipDel(&e);
|
||||
else if (e.ed_mode!='t')
|
||||
MeshVertexDel(&e,MeshVertexFindScrPt(&e,
|
||||
ms.presnap.x-Fs->pix_left-Fs->scroll_x,
|
||||
@@ -1103,9 +1103,9 @@ me_restart:
|
||||
break;
|
||||
case SC_INS:
|
||||
if (arg2&SCF_CTRL)
|
||||
goto me_clipboard_copy;
|
||||
goto me_clip_copy;
|
||||
else if (arg2&SCF_SHIFT)
|
||||
goto me_clipboard_paste;
|
||||
goto me_clip_paste;
|
||||
}
|
||||
break;
|
||||
case CH_BACKSPACE:
|
||||
@@ -1209,27 +1209,27 @@ me_chain:
|
||||
WinBorder(Bt(&Fs->display_flags,DISPLAYf_NO_BORDER));
|
||||
break;
|
||||
case CH_CTRLC:
|
||||
me_clipboard_copy:
|
||||
me_clip_copy:
|
||||
if (e.ed_mode=='t') {
|
||||
Beep;Beep;
|
||||
} else
|
||||
MeshClipboardCopy(&e);
|
||||
MeshClipCopy(&e);
|
||||
break;
|
||||
case CH_CTRLV:
|
||||
me_clipboard_paste:
|
||||
me_clip_paste:
|
||||
if (e.ed_mode=='t') {
|
||||
Beep;Beep;
|
||||
} else {
|
||||
MeshClipboardPaste(&e);
|
||||
MeshClipPaste(&e);
|
||||
e.ed_mode='m';
|
||||
}
|
||||
break;
|
||||
case CH_CTRLX:
|
||||
me_clipboard_cut:
|
||||
me_clip_cut:
|
||||
if (e.ed_mode=='t') {
|
||||
Beep;Beep;
|
||||
} else
|
||||
MeshClipboardCut(&e);
|
||||
MeshClipCut(&e);
|
||||
break;
|
||||
case CH_SHIFT_ESC:
|
||||
save_and_exit=FALSE;
|
||||
|
||||
+2
-2
@@ -59,8 +59,8 @@ Place the CDDVD %s in the drive.
|
||||
",iso_filename;
|
||||
}
|
||||
if (PressAKey!=CH_SHIFT_ESC) {
|
||||
">$FG,2$ChgDsk('T');$FG$\n\n";
|
||||
ChgDsk('T');
|
||||
">$FG,2$DskChg('T');$FG$\n\n";
|
||||
DskChg('T');
|
||||
res=TRUE;
|
||||
}
|
||||
} catch
|
||||
|
||||
@@ -35,19 +35,19 @@ public U0 BootHDIns(U8 drv_let=0)
|
||||
else {
|
||||
Free(de.full_name);
|
||||
"Modifying partition boot record.\n";
|
||||
RBlks(dv,&br,dv->drv_offset,1);
|
||||
BlkRead(dv,&br,dv->drv_offset,1);
|
||||
br.jump_and_nop[0]=OC_JMP_REL8;
|
||||
br.jump_and_nop[1]=offset(CFAT32Boot.code)-2;
|
||||
#assert offset(CFAT32Boot.code)>=offset(CRedSeaBoot.code)
|
||||
br.jump_and_nop[2]=OC_NOP;
|
||||
*BHD_BLK_CNT(U16 *)=(de.size+BLK_SIZE-1)>>BLK_SIZE_BITS;
|
||||
*BHD_DAP_BLK(I64 *)=Cluster2Blk(dv,de.cluster);
|
||||
*BHD_DAP_BLK(I64 *)=Clus2Blk(dv,de.clus);
|
||||
for (i=0;i<BHD_END-BHD_CODE;i++)
|
||||
br.code[i]=BHD_CODE(U8 *)[i];
|
||||
#assert sizeof(CFAT32Boot.code)>=BHD_END-BHD_CODE
|
||||
for (;i<sizeof(CFAT32Boot.code);i++)
|
||||
br.code[i]=0;
|
||||
WBlks(dv,&br,dv->drv_offset,1);
|
||||
BlkWrite(dv,&br,dv->drv_offset,1);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
|
||||
@@ -29,7 +29,7 @@ public U0 BootMHDOldRead(U8 src_drv,U8 dst_drv)
|
||||
BlkDevUnlock(bd);
|
||||
|
||||
Drv(dst_drv);
|
||||
MkDir(BOOT_DIR);
|
||||
DirMk(BOOT_DIR);
|
||||
FileWrite(BOOT_DIR_OLDMBR_BIN_C,&mbr,BLK_SIZE);
|
||||
}
|
||||
}
|
||||
@@ -103,7 +103,7 @@ public Bool BootMHDIns(U8 drv_let,U8 *drv_lst=NULL)
|
||||
j=0;
|
||||
if (FileFind(BOOT_DIR_OLDMBR_BIN_C,&de,FUF_JUST_FILES)) {
|
||||
Free(de.full_name);
|
||||
*_q++=Cluster2Blk(dv,de.cluster);
|
||||
*_q++=Clus2Blk(dv,de.clus);
|
||||
CatPrint(menu_ptr,"0. Old Boot Record\n\r");
|
||||
j++;
|
||||
}
|
||||
@@ -127,7 +127,7 @@ public Bool BootMHDIns(U8 drv_let,U8 *drv_lst=NULL)
|
||||
else {
|
||||
Free(de.full_name);
|
||||
*BMHD_BLK_CNT(U16 *)=(size+BLK_SIZE-1)>>BLK_SIZE_BITS;
|
||||
*BMHD_DAP_BLK(I64 *)=Cluster2Blk(dv,de.cluster);
|
||||
*BMHD_DAP_BLK(I64 *)=Clus2Blk(dv,de.clus);
|
||||
//Bypass partition bounds-checking
|
||||
BlkDevLock(bd);
|
||||
ATAReadBlks(bd,&mbr,0,1);
|
||||
|
||||
+18
-18
@@ -124,8 +124,8 @@ I64 DVDFileCreate2(CFile *out_file,CDirEntry *tmpde,CISO1DirEntry *tmpi,
|
||||
MemSet(buf,0,DVD_BLK_SIZE);
|
||||
}
|
||||
if (write) {
|
||||
FRBlks(in_file,buf,i<<2,n);
|
||||
FWBlks(out_file,buf,*_cur_blk<<2,n);
|
||||
FBlkRead(in_file,buf,i<<2,n);
|
||||
FBlkWrite(out_file,buf,*_cur_blk<<2,n);
|
||||
}
|
||||
*_cur_blk+=1;
|
||||
}
|
||||
@@ -181,7 +181,7 @@ I64 DVDFileCreate2(CFile *out_file,CDirEntry *tmpde,CISO1DirEntry *tmpi,
|
||||
if (write)
|
||||
"%X:%s\n",*_cur_blk,tmpde->full_name;
|
||||
if (write)
|
||||
FWBlks(out_file,dir_blk_buf,*_cur_blk<<2,n<<2);
|
||||
FBlkWrite(out_file,dir_blk_buf,*_cur_blk<<2,n<<2);
|
||||
*_cur_blk+=n;
|
||||
|
||||
tmpi2->len=sizeof(CISO1DirEntry)-1;
|
||||
@@ -212,7 +212,7 @@ I64 DVDFileCreate2(CFile *out_file,CDirEntry *tmpde,CISO1DirEntry *tmpi,
|
||||
if (write)
|
||||
"%X:%s\n",*_cur_blk,tmpde->full_name;
|
||||
if (write)
|
||||
FWBlks(out_file,dir_blk_buf2,*_cur_blk<<2,n<<2);
|
||||
FBlkWrite(out_file,dir_blk_buf2,*_cur_blk<<2,n<<2);
|
||||
*_cur_blk+=n;
|
||||
|
||||
Free(dir_blk_buf);
|
||||
@@ -328,7 +328,7 @@ public I64 ISO9660ISO(U8 *_filename=NULL,U8 *src_files_find_mask,
|
||||
|
||||
if (!_filename)
|
||||
_filename=blkdev.dft_iso_filename;
|
||||
filename=DftExt(_filename,"ISO");
|
||||
filename=ExtDft(_filename,"ISO");
|
||||
|
||||
if (_stage2_filename)
|
||||
stage2_filename=FileNameAbs(_stage2_filename);
|
||||
@@ -367,7 +367,7 @@ public I64 ISO9660ISO(U8 *_filename=NULL,U8 *src_files_find_mask,
|
||||
goto cf_done;
|
||||
|
||||
while (cur_blk<20<<2>>2)
|
||||
FWBlks(out_file,zero_buf,cur_blk++<<2,4);
|
||||
FBlkWrite(out_file,zero_buf,cur_blk++<<2,4);
|
||||
|
||||
iso_pri->type=ISO1T_PRI_VOL_DESC;
|
||||
StrCpy(iso_pri->id,"CD001");
|
||||
@@ -407,7 +407,7 @@ public I64 ISO9660ISO(U8 *_filename=NULL,U8 *src_files_find_mask,
|
||||
et->sect_cnt=4; //5 seems like the limit, 4 is safer
|
||||
et->load_rba=cur_blk+1;
|
||||
"%X: Pre Boot Blk\n",cur_blk;
|
||||
FWBlks(out_file,et,cur_blk++<<2,4);
|
||||
FBlkWrite(out_file,et,cur_blk++<<2,4);
|
||||
"%X: Boot Stage 1\n",cur_blk;
|
||||
cur_blk+=DVD_BOOT_LOADER_SIZE/DVD_BLK_SIZE;
|
||||
}
|
||||
@@ -434,10 +434,10 @@ public I64 ISO9660ISO(U8 *_filename=NULL,U8 *src_files_find_mask,
|
||||
for (i=1;i<=max_depth;i++)
|
||||
DVDFillPathTable(headdir,&itabbuf,&itabbuf2,1,FALSE,&first_free,1,i);
|
||||
"%X: Path Table 0\n",cur_blk;
|
||||
FWBlks(out_file,tabbuf,cur_blk<<2,tabsize<<2);
|
||||
FBlkWrite(out_file,tabbuf,cur_blk<<2,tabsize<<2);
|
||||
cur_blk+=tabsize;
|
||||
"%X: Path Table 1\n",cur_blk;
|
||||
FWBlks(out_file,tabbuf2,cur_blk<<2,tabsize2<<2);
|
||||
FBlkWrite(out_file,tabbuf2,cur_blk<<2,tabsize2<<2);
|
||||
cur_blk+=tabsize2;
|
||||
|
||||
MemSet(tabbuf,0,tabsize*DVD_BLK_SIZE);
|
||||
@@ -458,35 +458,35 @@ public I64 ISO9660ISO(U8 *_filename=NULL,U8 *src_files_find_mask,
|
||||
for (i=1;i<=max_depth;i++)
|
||||
DVDFillPathTable(headdir,&itabbuf,&itabbuf2,1,TRUE,&first_free,1,i);
|
||||
"%X: Path Table 2\n",cur_blk;
|
||||
FWBlks(out_file,tabbuf,cur_blk<<2,tabsize<<2);
|
||||
FBlkWrite(out_file,tabbuf,cur_blk<<2,tabsize<<2);
|
||||
cur_blk+=tabsize;
|
||||
"%X: Path Table 3\n",cur_blk;
|
||||
FWBlks(out_file,tabbuf2,cur_blk<<2,tabsize2<<2);
|
||||
FBlkWrite(out_file,tabbuf2,cur_blk<<2,tabsize2<<2);
|
||||
cur_blk+=tabsize2;
|
||||
|
||||
DirTreeDel2(headdir);
|
||||
FillU32Palindrome(&iso_pri->vol_space_size,cur_blk);
|
||||
FillU32Palindrome(&iso_sup->vol_space_size,cur_blk);
|
||||
FWBlks(out_file,iso_pri,16<<2,4);
|
||||
FBlkWrite(out_file,iso_pri,16<<2,4);
|
||||
|
||||
iso_term->type=ISO1T_TERMINATOR;
|
||||
StrCpy(iso_term->id,"CD001");
|
||||
iso_term->version=1;
|
||||
if (stage2_filename) {
|
||||
FWBlks(out_file,iso_boot,17<<2,4);
|
||||
FWBlks(out_file,iso_sup,18<<2,4);
|
||||
FWBlks(out_file,iso_term,19<<2,4);
|
||||
FBlkWrite(out_file,iso_boot,17<<2,4);
|
||||
FBlkWrite(out_file,iso_sup,18<<2,4);
|
||||
FBlkWrite(out_file,iso_term,19<<2,4);
|
||||
stage2_size=(Size(stage2_filename,"+s")+DVD_BLK_SIZE-1)/DVD_BLK_SIZE;
|
||||
MemCpy(stage1_buf,BDVD_START,BDVD_END-BDVD_START);
|
||||
*(BDVD_BLK_CNT-BDVD_START+stage1_buf)(U16 *)=stage2_size;
|
||||
*(BDVD_BLK_LO -BDVD_START+stage1_buf)(U32 *)=stage2_blk;
|
||||
"$$RED$$!!! Boot Stage 2 !!! %X-%X$$FG$$\n",
|
||||
stage2_blk,stage2_blk+stage2_size-1;
|
||||
FWBlks(out_file,stage1_buf,
|
||||
FBlkWrite(out_file,stage1_buf,
|
||||
20<<2+1<<2,DVD_BOOT_LOADER_SIZE/BLK_SIZE);
|
||||
} else {
|
||||
FWBlks(out_file,iso_sup,17<<2,4);
|
||||
FWBlks(out_file,iso_term,18<<2,4);
|
||||
FBlkWrite(out_file,iso_sup,17<<2,4);
|
||||
FBlkWrite(out_file,iso_term,18<<2,4);
|
||||
}
|
||||
|
||||
cf_done:
|
||||
|
||||
@@ -32,13 +32,13 @@ U0 RedSeaISO9660Stage1(U8 *iso_filename,U8 *stage2_filename)
|
||||
U8 *stage1_buf=CAlloc(DVD_BOOT_LOADER_SIZE);
|
||||
if (FileFind(stage2_filename,&de) && (out_file=FOpen(iso_filename,"wc+"))) {
|
||||
MemCpy(stage1_buf,BDVD_START,BDVD_END-BDVD_START);
|
||||
*(BDVD_BLK_LO -BDVD_START+stage1_buf)(U32 *)=de.cluster>>2;
|
||||
*(BDVD_BLK_LO -BDVD_START+stage1_buf)(U32 *)=de.clus>>2;
|
||||
*(BDVD_BLK_CNT -BDVD_START+stage1_buf)(U16 *)=
|
||||
(de.size+DVD_BLK_SIZE-1)>>(BLK_SIZE_BITS+2);
|
||||
*(BDVD_SHIFT_BLKS -BDVD_START+stage1_buf)(U16 *)=de.cluster&3;
|
||||
if (de.cluster&3)
|
||||
*(BDVD_SHIFT_BLKS -BDVD_START+stage1_buf)(U16 *)=de.clus&3;
|
||||
if (de.clus&3)
|
||||
*(BDVD_BLK_CNT -BDVD_START+stage1_buf)(U16 *)+=1;
|
||||
FWBlks(out_file,stage1_buf,
|
||||
FBlkWrite(out_file,stage1_buf,
|
||||
20<<2+1<<2,DVD_BOOT_LOADER_SIZE/BLK_SIZE);
|
||||
FClose(out_file);
|
||||
}
|
||||
@@ -61,7 +61,7 @@ U0 RedSeaISO9660(U8 *iso_filename,U8 drv_let)
|
||||
if (out_file=FOpen(iso_filename,"wc+")) {
|
||||
iso_size=FSize(out_file)/DVD_BLK_SIZE;
|
||||
for (i=0;i<dv->bd->drv_offset;i+=4)
|
||||
FWBlks(out_file,zero_buf,i,4);
|
||||
FBlkWrite(out_file,zero_buf,i,4);
|
||||
|
||||
iso_pri->type=ISO1T_PRI_VOL_DESC;
|
||||
StrCpy(iso_pri->id,"CD001");
|
||||
@@ -70,7 +70,7 @@ U0 RedSeaISO9660(U8 *iso_filename,U8 drv_let)
|
||||
FillU16Palindrome(&iso_pri->vol_seq_num,1);
|
||||
FillU16Palindrome(&iso_pri->log_block_size,DVD_BLK_SIZE);
|
||||
FillU32Palindrome(&iso_pri->vol_space_size,iso_size);
|
||||
FillU32Palindrome(&iso_pri->root_dir_record,dv->root_cluster);
|
||||
FillU32Palindrome(&iso_pri->root_dir_record,dv->root_clus);
|
||||
iso_pri->file_structure_version=1;
|
||||
StrCpy(iso_pri->publisher_id,"TempleOS RedSea");
|
||||
|
||||
@@ -82,17 +82,17 @@ U0 RedSeaISO9660(U8 *iso_filename,U8 drv_let)
|
||||
iso_boot->version=1;
|
||||
StrCpy(iso_boot(U8 *)+7,"EL TORITO SPECIFICATION");
|
||||
|
||||
FWBlks(out_file,iso_pri,16<<2,4);
|
||||
FBlkWrite(out_file,iso_pri,16<<2,4);
|
||||
iso_term->type=ISO1T_TERMINATOR;
|
||||
StrCpy(iso_term->id,"CD001");
|
||||
iso_term->version=1;
|
||||
|
||||
d=iso_boot(U8 *)+0x47;
|
||||
*d=20<<2>>2;
|
||||
FWBlks(out_file,iso_boot,17<<2,4);
|
||||
FBlkWrite(out_file,iso_boot,17<<2,4);
|
||||
|
||||
FWBlks(out_file,iso_sup,18<<2,4);
|
||||
FWBlks(out_file,iso_term,19<<2,4);
|
||||
FBlkWrite(out_file,iso_sup,18<<2,4);
|
||||
FBlkWrite(out_file,iso_term,19<<2,4);
|
||||
|
||||
et->w[0]=1;
|
||||
StrCpy(&et->w[2],"TempleOS");
|
||||
@@ -105,7 +105,7 @@ U0 RedSeaISO9660(U8 *iso_filename,U8 drv_let)
|
||||
et->media_type=0;//0=no emu 2=1.44meg 4=hard drive
|
||||
et->sect_cnt=4; //5 seems like the limit, 4 is safer
|
||||
et->load_rba=20<<2>>2+1;
|
||||
FWBlks(out_file,et,20<<2,4);
|
||||
FBlkWrite(out_file,et,20<<2,4);
|
||||
FClose(out_file);
|
||||
}
|
||||
Free(zero_buf);
|
||||
@@ -147,7 +147,7 @@ public I64 RedSeaISO(U8 *_iso_filename=NULL,U8 *_src_dir,
|
||||
else {
|
||||
if (!_iso_filename)
|
||||
_iso_filename=blkdev.dft_iso_c_filename;
|
||||
iso_filename=ChgExt(_iso_filename,"ISO.C");
|
||||
iso_filename=ExtChg(_iso_filename,"ISO.C");
|
||||
src_dir=DirNameAbs(_src_dir);
|
||||
if (_stage2_filename) {
|
||||
stage2_filename=FileNameAbs(_stage2_filename);
|
||||
|
||||
@@ -63,7 +63,7 @@ I64 SizeRep1(CDirEntry *tmpde,I64 *_fuf_flags)
|
||||
else if ((i=tmpde->size) && Bt(_fuf_flags,FUf_EXPAND) &&
|
||||
FileAttr(tmpde->name)&RS_ATTR_COMPRESSED) {
|
||||
dv=Let2Drv(*tmpde->full_name);
|
||||
RBlks(dv,buf,Cluster2Blk(dv,tmpde->cluster),1);
|
||||
BlkRead(dv,buf,Clus2Blk(dv,tmpde->clus),1);
|
||||
i=(&buf)(CArcCompress *)->expanded_size;
|
||||
}
|
||||
tmpde->user_data=i;
|
||||
|
||||
@@ -71,7 +71,7 @@ I64 BlkDevsSize()
|
||||
j=(bd->max_blk+1)<<BLK_SIZE_BITS;
|
||||
if (bd->type==BDT_RAM)
|
||||
"RAMDsk %C\t:%010X/%010X\n",
|
||||
bd->first_drv_let,j-UnusedDrvSpace(bd->first_drv_let),j;
|
||||
bd->first_drv_let,j-DrvUnused(bd->first_drv_let),j;
|
||||
res+=MSize2(bd->dev_id_record);
|
||||
}
|
||||
}
|
||||
@@ -115,7 +115,7 @@ Bool MemRepTask(CTask *task,Bool override_validate=FALSE)
|
||||
|
||||
"HashTable\t:%010X\n",HashTableSize2(task->hash_table);
|
||||
"FPU\t\t:%010X\n",MSize2(task->fpu_mmx);
|
||||
"CurDir\t:%010X\n",MSize2(task->cur_dir);
|
||||
"DirCur\t:%010X\n",MSize2(task->cur_dir);
|
||||
|
||||
if (pdoc=DocPut(task))
|
||||
"PutDoc\t:%010X\n",DocSize(pdoc);
|
||||
@@ -172,7 +172,7 @@ Bool MemRepTask(CTask *task,Bool override_validate=FALSE)
|
||||
"DskCache\t:%010X\n",
|
||||
MSize2(blkdev.cache_base)+MSize2(blkdev.cache_hash_table)+
|
||||
MSize2(blkdev.cache_ctrl);
|
||||
"Clipboard\t:%010X\n",DocSize(sys_clipboard_doc);
|
||||
"Clip\t:%010X\n",DocSize(sys_clip_doc);
|
||||
"AutoComplete:%010X\n",CallExtStr("AutoCompleteSize");
|
||||
"gr.to_8_bits\t:%010X\n",MSize2(gr.to_8_bits);
|
||||
"gr.to_8_colors\t:%010X\n",MSize2(gr.to_8_colors);
|
||||
|
||||
@@ -14,9 +14,9 @@ public I64 Sort(U8 *_in_name,U8 *_out_name=NULL,
|
||||
I64 i,j,cnt=0,res;
|
||||
|
||||
if (!_in_name) return 0;
|
||||
in_name=DftExt(_in_name,"DD.Z");
|
||||
in_name=ExtDft(_in_name,"DD.Z");
|
||||
if (_out_name)
|
||||
out_name=DftExt(_out_name,"DD.Z");
|
||||
out_name=ExtDft(_out_name,"DD.Z");
|
||||
else
|
||||
out_name=StrNew(in_name);
|
||||
|
||||
|
||||
@@ -112,11 +112,11 @@ public U0 ToTXT(U8 *_in_name,U8 *_out_name=NULL,I64 width=70)
|
||||
SettingsPush; //See $LK,"SettingsPush",A="MN:SettingsPush"$
|
||||
WinHorz(0,width-1); //Sets doc width for word wrap.
|
||||
|
||||
in_name=DftExt(_in_name,"DD.Z");
|
||||
in_name=ExtDft(_in_name,"DD.Z");
|
||||
if (_out_name)
|
||||
out_name=DftExt(_out_name,"TXT");
|
||||
out_name=ExtDft(_out_name,"TXT");
|
||||
else
|
||||
out_name=ChgExt(_in_name,"TXT");
|
||||
out_name=ExtChg(_in_name,"TXT");
|
||||
|
||||
doc_in=DocRead(in_name);
|
||||
doc_out=Doc2TXT(doc_in);
|
||||
|
||||
@@ -10,7 +10,7 @@ public CTaskSettings *SettingsPush(CTask *task=NULL,I64 flags=0)
|
||||
if (!task) task=Fs;
|
||||
if (!TaskValidate(task)) return NULL;
|
||||
tmpse=CAlloc(sizeof(CTaskSettings),task);
|
||||
tmpse->cur_dir=CurDir(task,task);
|
||||
tmpse->cur_dir=DirCur(task,task);
|
||||
tmpse->draw_it=task->draw_it;
|
||||
GrPaletteGet(tmpse->palette);
|
||||
tmpse->task_end_cb=task->task_end_cb;
|
||||
|
||||
@@ -343,6 +343,7 @@ ext[EXT_WIN_TO_TOP]=&WinToTop;
|
||||
|
||||
public CTask *WinFocus(CTask *task=NULL)
|
||||
{//Set task as focus task.
|
||||
if (!task) task=Fs;
|
||||
PUSHFD
|
||||
CLI
|
||||
if (!TaskValidate(task)||Bt(&task->win_inhibit,WIf_SELF_FOCUS))
|
||||
|
||||
+8
-18
@@ -2,7 +2,7 @@
|
||||
|
||||
public U0 Refresh(I64 cnt=1,Bool force=FALSE)
|
||||
{//Wait for 30fps WinMgr to start & finish scrn refresh.
|
||||
//0,FALSE Cnt Sync to WinMgr. (not used)
|
||||
//0,FALSE Cnt Sync to WinMgr. (not used)
|
||||
//0,TRUE Pump Msgs.
|
||||
//1 Cnt Wait and Pump Msgs.
|
||||
//2 Cnt Make Sure to do a Full Refresh
|
||||
@@ -14,20 +14,16 @@ public U0 Refresh(I64 cnt=1,Bool force=FALSE)
|
||||
if (!cnt&&force)
|
||||
LBts(&sys_semas[SEMA_JUST_PUMP_MSGS],0);
|
||||
while (Bt(&sys_semas[SEMA_REFRESH_IN_PROGRESS],0)) {
|
||||
if (force) {
|
||||
LBts(&sys_semas[SEMA_FORCE_WINMGR],0);
|
||||
if (sys_winmgr_task) sys_winmgr_task->wake_jiffy=cnts.jiffies;
|
||||
}
|
||||
if (force && sys_winmgr_task)
|
||||
sys_winmgr_task->wake_jiffy=cnts.jiffies;
|
||||
Yield;
|
||||
}
|
||||
if (cnt>1 && old_doc)
|
||||
old_full_refresh=LBts(&old_doc->flags,DOCf_DO_FULL_REFRESH);
|
||||
update_cnt=winmgr.updates+cnt;
|
||||
while (winmgr.updates<update_cnt) {
|
||||
if (force) {
|
||||
LBts(&sys_semas[SEMA_FORCE_WINMGR],0);
|
||||
if (sys_winmgr_task) sys_winmgr_task->wake_jiffy=cnts.jiffies;
|
||||
}
|
||||
if (force && sys_winmgr_task)
|
||||
sys_winmgr_task->wake_jiffy=cnts.jiffies;
|
||||
Sleep(1);
|
||||
}
|
||||
if (old_doc)
|
||||
@@ -281,16 +277,10 @@ I64 WinMgrSleep(Bool flush_msgs=FALSE)
|
||||
music.cur_song_task=NULL;
|
||||
}
|
||||
winmgr.updates++;
|
||||
if (!ms_hard.install_attempts)
|
||||
SleepUntil(timeout_val); //Just for before mouse install attempt at boot.
|
||||
else
|
||||
do {
|
||||
KbdMsHndlr(FALSE,TRUE);
|
||||
SleepUntil(MinI64(timeout_val,cnts.jiffies+JIFFY_FREQ/500));
|
||||
} while (cnts.jiffies<timeout_val &&
|
||||
!Bt(&sys_semas[SEMA_FORCE_WINMGR],0));
|
||||
if (ms_hard.install_attempts) //Don't call before boot mouse install attempt
|
||||
KbdMsHndlr(FALSE,TRUE);
|
||||
SleepUntil(timeout_val);
|
||||
}
|
||||
LBtr(&sys_semas[SEMA_FORCE_WINMGR],0);
|
||||
return msg_code;
|
||||
}
|
||||
|
||||
|
||||
@@ -35,11 +35,11 @@ U0 BgtIns(CBgtEntry *tmpb)
|
||||
|
||||
class CBgtEntryForm
|
||||
{
|
||||
U8 date[512] fmtstr "$$DA-P,A=\"Date :%s\"$$\n";
|
||||
F64 amount fmtstr "Amount $$$$$$DA,A=\"%8.2f\"$$\n";
|
||||
U8 credit[512] fmtstr "$$DA-P,A=\"Credit Acct:%s\"$$\n";
|
||||
U8 debit [512] fmtstr "$$DA-P,A=\"Debit Acct:%s\"$$\n";
|
||||
U8 desc [512] fmtstr "$$DA-P,A=\"Desc :%s\"$$\n";
|
||||
U8 date[512] fmtstr "$$DA-P,A=\"Date :%s\"$$\n";
|
||||
F64 amount fmtstr "Amount $$$$$$DA,A=\"%10.2f\"$$\n";
|
||||
U8 credit[512] fmtstr "$$DA-P,A=\"Credit (from) Acct:%s\"$$\n";
|
||||
U8 debit [512] fmtstr "$$DA-P,A=\"Debit (to) Acct:%s\"$$\n";
|
||||
U8 desc [512] fmtstr "$$DA-P,A=\"Desc :%s\"$$\n";
|
||||
};
|
||||
|
||||
CBgtEntry *BgtEntryPmt(CBgtEntry *dft=NULL)
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
Cd(__DIR__);;
|
||||
if (!FileFind("~/Budget",,FUF_JUST_DIRS)) {
|
||||
MkDir("~/Budget");
|
||||
DirMk("~/Budget");
|
||||
Copy("Accts.DD.Z","~/Budget");
|
||||
}
|
||||
|
||||
@@ -2,13 +2,13 @@ $WW,1$$FG,5$$TX+CX,"Psalmody Help"$$FG$
|
||||
|
||||
* The keyboard can be used as an organ by typing letter keys or clicking the mouse on the keyboard diagram$FG$. You can "record" notes by pressing the red bttn and typing letters. They will appear on the musical staff. You can edit and save them.
|
||||
|
||||
* The clipboard can be used to cut and paste.
|
||||
* The clip can be used to cut and paste.
|
||||
|
||||
* $FG,2$Psalmody$FG$ uses $LK,"HolyC",A="FI:::/Doc/HolyC.DD"$ files as the song format! See $LK,"::/Apps/Psalmody/Examples/prosper.HC"$. The $FG,2$Psalmody$FG$ program does not fully parse the songs when loading them back in, so changes made outside $FG,2$Psalmody$FG$ will be lost, like if you add graphics.
|
||||
|
||||
* The first line of the $LK,"HolyC",A="FI:::/Doc/HolyC.DD"$ song files is a comment with a category recognized by $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). The categories are $FG,2$"no nothing"$FG$, $FG,2$"has words"$FG$, $FG,2$"has graphics"$FG$, or $FG,2$"special"$FG$. The third character in the song comment is a digit rating number, shown in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). You can set the song rating in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$() by pressing $FG,2$0$FG$-$FG,2$9$FG$. You can press $FG,2$<DELETE>$FG$ to delete songs.
|
||||
* The first line of the $LK,"HolyC",A="FI:::/Doc/HolyC.DD"$ song files is a comment with a category recognized by $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). The categories are $FG,2$"no nothing"$FG$, $FG,2$"has words"$FG$, $FG,2$"has graphics"$FG$, or $FG,2$"special"$FG$. The third character in the song comment is a digit rating number, shown in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). You can set the song rating in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$() by pressing $FG,2$0$FG$-$FG,2$9$FG$. You can request your reward from God by pressing $FG,2$r$FG$. You can press $FG,2$<DEL>$FG$ to delete songs.
|
||||
|
||||
* You can take the $LK,"Play",A="MN:Play"$() stmts out of a song file and place them in your programs. You can also add a song to a document with $FG,2$<CTRL-l>$FG$, but you should do it after pressing $FG,2$<CTRL-t>$FG$ because the clipboard-insert in $FG,2$<CTRL-l>$FG$ is screwy. See this $SO,"<Song>",A="4qG5EC4BeGG5qCeFD4sB5G4B5G4qG5EC4BeGG5qCeFD4sB5G4B5GqEeEFqE4BeG5FetC4A5GqFCEeEFqE4BeG5FetC4A5GqFC"$ after pressing $FG,2$<CTRL-t>$FG$, now.
|
||||
* You can take the $LK,"Play",A="MN:Play"$() stmts out of a song file and place them in your programs. You can also add a song to a document with $FG,2$<CTRL-l>$FG$, but you should do it after pressing $FG,2$<CTRL-t>$FG$ because the clip-insert in $FG,2$<CTRL-l>$FG$ is screwy. See this $SO,"<Song>",A="4qG5EC4BeGG5qCeFD4sB5G4B5G4qG5EC4BeGG5qCeFD4sB5G4B5GqEeEFqE4BeG5FetC4A5GqFCEeEFqE4BeG5FetC4A5GqFC"$ after pressing $FG,2$<CTRL-t>$FG$, now.
|
||||
|
||||
* You can call $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$("~/Psalmody"); to play your songs.
|
||||
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
if (!FileFind("~/Psalmody",,FUF_JUST_DIRS))
|
||||
MkDir("~/Psalmody");
|
||||
DirMk("~/Psalmody");
|
||||
|
||||
+142
-80
@@ -1,3 +1,30 @@
|
||||
CTask *JukeReward(U8 *msg)
|
||||
{
|
||||
U8 *buf;
|
||||
CDoc *doc;
|
||||
CTask *res=Spawn(&SrvCmdLine,NULL,"Reward",,Fs);
|
||||
StrCpy(res->task_title,"Reward");
|
||||
res->title_src=TTS_LOCKED_CONST;
|
||||
|
||||
doc=DocNew(,res);
|
||||
DocPrint(doc,"$$WW+H,1$$%s",msg);
|
||||
|
||||
buf=MStrPrint("DocEd(0x%X);",doc);
|
||||
TaskExe(res,NULL,buf,1<<JOBf_EXIT_ON_COMPLETE|1<<JOBf_FREE_ON_COMPLETE);
|
||||
Free(buf);
|
||||
TaskWait(res);
|
||||
|
||||
res->border_src =BDS_CONST;
|
||||
res->border_attr=LTGRAY<<4+DrvTextAttrGet(':')&15;
|
||||
res->text_attr =LTGRAY<<4+BLUE;
|
||||
res->win_inhibit=WIG_NO_FOCUS_TASK_DFT;
|
||||
WinHorz(Fs->win_right+2,TEXT_COLS-2,res);
|
||||
WinVert(2,TEXT_ROWS-2,res);
|
||||
|
||||
WinFocus(Fs->parent_task);
|
||||
return res;
|
||||
}
|
||||
|
||||
CTask *SingleSong(U8 *msg,U8 *name)
|
||||
{
|
||||
CTask *task=Spawn(&SrvCmdLine,NULL,name,,Fs);
|
||||
@@ -6,6 +33,7 @@ CTask *SingleSong(U8 *msg,U8 *name)
|
||||
TaskExe(task,Fs,";",1<<JOBf_WAKE_MASTER|1<<JOBf_FREE_ON_COMPLETE);
|
||||
WinHorz(task->win_left,task->win_left+50,task);
|
||||
WinVert(2,2+8,task);
|
||||
task->win_inhibit=WIG_NO_FOCUS_TASK_DFT;
|
||||
TaskExe(task,NULL,msg,1<<JOBf_EXIT_ON_COMPLETE|1<<JOBf_FREE_ON_COMPLETE);
|
||||
DocPut(task)->max_entries=100;
|
||||
return task;
|
||||
@@ -19,7 +47,9 @@ Bool JBPutKey(CDoc *doc,U8 *,I64 ch,I64 sc)
|
||||
{//ch=ASCII; sc=scan_code
|
||||
CDocEntry *doc_ce=doc->cur_entry,*doc_e;
|
||||
CDirEntry *tmpde;
|
||||
CDoc *s;
|
||||
I64 i;
|
||||
U8 *st;
|
||||
CDoc *doc2;
|
||||
if (!(sc&(SCF_ALT|SCF_CTRL|SCF_SHIFT))
|
||||
&& doc_ce->type_u8==DOCT_MENU_VAL && doc_ce->left_exp>=0) {
|
||||
tmpde=doc_ce->left_exp;
|
||||
@@ -31,20 +61,45 @@ Bool JBPutKey(CDoc *doc,U8 *,I64 ch,I64 sc)
|
||||
} else if ('0'<=ch<='9') {
|
||||
if (StrLen(doc_ce->tag)>1)
|
||||
doc_ce->tag[0]=ch;
|
||||
s=DocRead(tmpde->full_name);
|
||||
doc_e=s->head.next;
|
||||
while (doc_e!=s && doc_e->type_u8!=DOCT_TEXT)
|
||||
doc_e=doc_e->next;
|
||||
if (doc_e!=s && doc_e->type_u8==DOCT_TEXT && StrLen(doc_e->tag)>=3) {
|
||||
doc2=DocRead(tmpde->full_name);
|
||||
DocGoToLine(doc2,1);
|
||||
doc_e=doc2->cur_entry;
|
||||
if (doc_e!=doc2 && doc_e->type_u8==DOCT_TEXT && StrLen(doc_e->tag)>=3) {
|
||||
doc_e->tag[2]=ch;
|
||||
DocWrite(s);
|
||||
DocWrite(doc2);
|
||||
}
|
||||
DocDel(doc2);
|
||||
return TRUE;
|
||||
} else if (ch=='r') {
|
||||
if (!DocTreeFFind(tmpde->full_name,"Reward1")) {
|
||||
doc2=DocRead(tmpde->full_name);
|
||||
DocGoToLine(doc2,2);
|
||||
DocPrint(doc2,
|
||||
"\n$$TR,\"Reward1\"$$\n"
|
||||
"$$ID,2$$CallExtStr(\"JukeReward\",\"\"\n"
|
||||
"$$TR,\"Reward2\"$$\n"
|
||||
"$$ID,2$$\n"
|
||||
"$$ID,-2$$\n"
|
||||
");\n$$ID,-2$$\n"
|
||||
);
|
||||
DocWrite(doc2);
|
||||
DocDel(doc2);
|
||||
}
|
||||
if (DocTreeFFind(tmpde->full_name,"Reward1/Reward2")) {
|
||||
for (i=0;i<5;i++) {
|
||||
st=MStrPrint("%s %s %s %s ",
|
||||
GodWordStr,GodWordStr,GodWordStr,GodWordStr);
|
||||
DocTreeFAppend(tmpde->full_name,"Reward1/Reward2",
|
||||
"\"%s\"\n",st);
|
||||
Free(st);
|
||||
}
|
||||
In(" ");
|
||||
}
|
||||
DocDel(s);
|
||||
return TRUE;
|
||||
} else if (ch==CH_SPACE||ch==CH_ESC)
|
||||
tmpde->user_data++; //JB_RUN_LEVEL++
|
||||
//<SPACE> is followed by <ESC> --> JB_RUN_LEVEL_TWO
|
||||
//Actual <ESC> just exits --> JB_RUN_LEVEL_ONE
|
||||
//Actual <ESC> just exits --> JB_RUN_LEVEL_ONE
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
@@ -59,80 +114,87 @@ public U0 JukeBox(U8 *dirname="~/Psalmody",U8 **_filename=NULL)
|
||||
CTask *task=NULL;
|
||||
if (_filename)
|
||||
*_filename=NULL;
|
||||
dirname=StrNew(dirname);
|
||||
st=MStrPrint("%s/*.HC.Z",dirname);
|
||||
tmpde=tmpde1=FilesFind(st);
|
||||
Free(st);
|
||||
Free(dirname);
|
||||
doc->user_put_key=&JBPutKey;
|
||||
DocPrint(doc,
|
||||
"Key: $$GREEN$$Graphics $$BLUE$$Words $$RED$$No Nothing "
|
||||
"$$BLACK$$Incomplete $$CYAN$$Special$$FG$$\n\n"
|
||||
"$$GREEN$$<DELETE>$$FG$$ to delete a song.\n"
|
||||
"Press a number to rate a song.\n");
|
||||
while (tmpde) {
|
||||
if (!(i++%5))
|
||||
DocPrint(doc,"\n");
|
||||
if (FileOcc("Play(",tmpde->full_name,"")) {
|
||||
st=StrNew(tmpde->name);
|
||||
FileExtRem(st);
|
||||
s=DocRead(tmpde->full_name);
|
||||
doc_e=s->head.next;
|
||||
while (doc_e!=s && doc_e->type_u8!=DOCT_TEXT)
|
||||
doc_e=doc_e->next;
|
||||
rating='0';
|
||||
if (doc_e!=s && doc_e->type_u8==DOCT_TEXT) {
|
||||
if ('0'<=doc_e->tag[2]<='9')
|
||||
rating=doc_e->tag[2];
|
||||
if (StrMatch("incomplete",doc_e->tag))
|
||||
DocPrint(doc,"$$BLACK$$");
|
||||
else if (StrMatch("has graphics",doc_e->tag))
|
||||
DocPrint(doc,"$$GREEN$$");
|
||||
else if (StrMatch("has words",doc_e->tag))
|
||||
DocPrint(doc,"$$BLUE$$");
|
||||
else if (StrMatch("special",doc_e->tag))
|
||||
DocPrint(doc,"$$CYAN$$");
|
||||
else if (StrMatch("no nothing",doc_e->tag)) {
|
||||
DocPrint(doc,"$$RED$$");
|
||||
if (FileOcc("\\0",tmpde->full_name,"")) {
|
||||
s->cur_entry=doc_e->next;
|
||||
s->cur_col=0;
|
||||
DocEntryDel(s,doc_e);
|
||||
DocPrint(s,"//0 has words\n");
|
||||
DocWrite(s);
|
||||
SettingsPush; //See $LK,"SettingsPush",A="MN:SettingsPush"$
|
||||
AutoComplete;
|
||||
try {
|
||||
dirname=StrNew(dirname);
|
||||
st=MStrPrint("%s/*.HC.Z",dirname);
|
||||
tmpde=tmpde1=FilesFind(st);
|
||||
Free(st);
|
||||
Free(dirname);
|
||||
doc->user_put_key=&JBPutKey;
|
||||
DocPrint(doc,
|
||||
"Key: $$GREEN$$Graphics $$BLUE$$Words $$RED$$No Nothing "
|
||||
"$$BLACK$$Incomplete $$CYAN$$Special$$FG$$\n\n"
|
||||
"$$GREEN$$<DEL>$$FG$$\tto delete a song.\n"
|
||||
"'$$GREEN$$0$$FG$$'-'$$GREEN$$9$$FG$$'\tto rate a song.\n"
|
||||
"'$$GREEN$$r$$FG$$'\tto get your reward from God.\n");
|
||||
while (tmpde) {
|
||||
if (!(i++%5))
|
||||
DocPrint(doc,"\n");
|
||||
if (FileOcc("Play(",tmpde->full_name,"")) {
|
||||
st=StrNew(tmpde->name);
|
||||
FileExtRem(st);
|
||||
s=DocRead(tmpde->full_name);
|
||||
doc_e=s->head.next;
|
||||
while (doc_e!=s && doc_e->type_u8!=DOCT_TEXT)
|
||||
doc_e=doc_e->next;
|
||||
rating='0';
|
||||
if (doc_e!=s && doc_e->type_u8==DOCT_TEXT) {
|
||||
if ('0'<=doc_e->tag[2]<='9')
|
||||
rating=doc_e->tag[2];
|
||||
if (StrMatch("incomplete",doc_e->tag))
|
||||
DocPrint(doc,"$$BLACK$$");
|
||||
else if (StrMatch("has graphics",doc_e->tag))
|
||||
DocPrint(doc,"$$GREEN$$");
|
||||
else if (StrMatch("has words",doc_e->tag))
|
||||
DocPrint(doc,"$$BLUE$$");
|
||||
else if (StrMatch("special",doc_e->tag))
|
||||
DocPrint(doc,"$$CYAN$$");
|
||||
else if (StrMatch("no nothing",doc_e->tag)) {
|
||||
DocPrint(doc,"$$RED$$");
|
||||
if (FileOcc("\\0",tmpde->full_name,"")) {
|
||||
s->cur_entry=doc_e->next;
|
||||
s->cur_col=0;
|
||||
DocEntryDel(s,doc_e);
|
||||
DocPrint(s,"//0 has words\n");
|
||||
DocWrite(s);
|
||||
}
|
||||
}
|
||||
DocPrint(doc,"$$MU-UL,\"%c%-8ts\",LE=%d$$ ",rating,st,tmpde);
|
||||
tmpde->user_data=JB_RUN_LEVEL_NULL;
|
||||
}
|
||||
DocPrint(doc,"$$MU-UL,\"%c%-8ts\",LE=%d$$ ",rating,st,tmpde);
|
||||
tmpde->user_data=JB_RUN_LEVEL_NULL;
|
||||
DocDel(s);
|
||||
Free(st);
|
||||
}
|
||||
DocDel(s);
|
||||
tmpde=tmpde->next;
|
||||
}
|
||||
DocPrint(doc,"\n$$CYAN$$$$MU-UL,\"DONE\",LE=%d$$\n",DOCM_CANCEL);
|
||||
while (TRUE) {
|
||||
if (_filename)
|
||||
tmpde=PopUpMenu(doc,DOF_INTERCEPT_TASK_END);
|
||||
else
|
||||
tmpde=PopUpMenu(doc);
|
||||
if (task)
|
||||
Kill(task);
|
||||
if (tmpde<=0) break;
|
||||
st2=StrNew(tmpde->name);
|
||||
if (_filename) {
|
||||
Free(*_filename);
|
||||
*_filename=StrNew(tmpde->full_name);
|
||||
}
|
||||
if (tmpde->user_data==JB_RUN_LEVEL_ONE) break; //<ESC>
|
||||
tmpde->user_data=JB_RUN_LEVEL_NULL; //Rst from <SPACE>
|
||||
FileExtRem(st2);
|
||||
st=MStrPrint("ExeFile(\"%s\");",tmpde->full_name);
|
||||
MusicSettingsRst;
|
||||
task=SingleSong(st,st2);
|
||||
Free(st2);
|
||||
Free(st);
|
||||
}
|
||||
tmpde=tmpde->next;
|
||||
}
|
||||
DocPrint(doc,"\n$$CYAN$$$$MU-UL,\"DONE\",LE=%d$$\n",DOCM_CANCEL);
|
||||
while (TRUE) {
|
||||
if (_filename)
|
||||
tmpde=PopUpMenu(doc,DOF_INTERCEPT_TASK_END);
|
||||
else
|
||||
tmpde=PopUpMenu(doc);
|
||||
if (task)
|
||||
Kill(task);
|
||||
if (tmpde<=0) break;
|
||||
st2=StrNew(tmpde->name);
|
||||
if (_filename) {
|
||||
Free(*_filename);
|
||||
*_filename=StrNew(tmpde->full_name);
|
||||
}
|
||||
if (tmpde->user_data==JB_RUN_LEVEL_ONE) break; //<ESC>
|
||||
tmpde->user_data=JB_RUN_LEVEL_NULL; //Rst from <SPACE>
|
||||
FileExtRem(st2);
|
||||
st=MStrPrint("ExeFile(\"%s\");",tmpde->full_name);
|
||||
MusicSettingsRst;
|
||||
task=SingleSong(st,st2);
|
||||
Free(st2);
|
||||
Free(st);
|
||||
}
|
||||
DocDel(doc);
|
||||
DirTreeDel(tmpde1);
|
||||
DocDel(doc);
|
||||
DirTreeDel(tmpde1);
|
||||
} catch
|
||||
PutExcept;
|
||||
SettingsPop;
|
||||
}
|
||||
|
||||
@@ -50,7 +50,7 @@ class PsmNote
|
||||
class PsmCtrl
|
||||
{
|
||||
PsmNote head;
|
||||
PsmNote clipboard;
|
||||
PsmNote clip;
|
||||
CMenuEntry *incomplete_entry,*record_entry;
|
||||
I64 scrn_x,tool;
|
||||
PsmNote *cur_note;
|
||||
|
||||
@@ -26,10 +26,10 @@ U0 PsmSongDel(PsmNote *head)
|
||||
QueInit(head);
|
||||
}
|
||||
|
||||
U0 PsmCutToClipboard()
|
||||
U0 PsmCutToClip()
|
||||
{
|
||||
PsmNote *tmpn,*tmpn1;
|
||||
PsmSongDel(&psm.clipboard);
|
||||
PsmSongDel(&psm.clip);
|
||||
tmpn=psm.head.next;
|
||||
while (tmpn!=&psm.head) {
|
||||
tmpn1=tmpn->next;
|
||||
@@ -38,33 +38,33 @@ U0 PsmCutToClipboard()
|
||||
psm.cur_note=tmpn->next;
|
||||
QueRem(tmpn);
|
||||
tmpn->flags&=~PSMF_SEL;
|
||||
QueIns(tmpn,psm.clipboard.last);
|
||||
QueIns(tmpn,psm.clip.last);
|
||||
}
|
||||
tmpn=tmpn1;
|
||||
}
|
||||
}
|
||||
|
||||
U0 PsmPasteClipboard()
|
||||
U0 PsmPasteClip()
|
||||
{
|
||||
PsmNote *tmpn,*tmpn1;
|
||||
tmpn=psm.clipboard.next;
|
||||
while (tmpn!=&psm.clipboard) {
|
||||
tmpn=psm.clip.next;
|
||||
while (tmpn!=&psm.clip) {
|
||||
tmpn1=PsmNoteCopy(tmpn);
|
||||
QueIns(tmpn1,psm.cur_note->last);
|
||||
tmpn=tmpn->next;
|
||||
}
|
||||
}
|
||||
|
||||
U0 PsmCopyToClipboard()
|
||||
U0 PsmCopyToClip()
|
||||
{
|
||||
PsmNote *tmpn,*tmpn1;
|
||||
PsmSongDel(&psm.clipboard);
|
||||
PsmSongDel(&psm.clip);
|
||||
tmpn=psm.head.next;
|
||||
while (tmpn!=&psm.head) {
|
||||
if (tmpn->flags&PSMF_SEL) {
|
||||
tmpn->flags&=~PSMF_SEL;
|
||||
tmpn1=PsmNoteCopy(tmpn);
|
||||
QueIns(tmpn1,psm.clipboard.last);
|
||||
QueIns(tmpn1,psm.clip.last);
|
||||
}
|
||||
tmpn=tmpn->next;
|
||||
}
|
||||
|
||||
@@ -369,7 +369,7 @@ U0 Psalmody(U8 *dirname="~/Psalmody")
|
||||
MemSet(&psm,0,sizeof(PsmCtrl));
|
||||
psm.scrn_x=0;
|
||||
psm.head.next=psm.head.last=&psm.head;
|
||||
psm.clipboard.next=psm.clipboard.last=&psm.clipboard;
|
||||
psm.clip.next=psm.clip.last=&psm.clip;
|
||||
psm.cur_note=&psm.head;
|
||||
psm.dc2=DCAlias;
|
||||
|
||||
@@ -543,7 +543,7 @@ mo_got_msg:
|
||||
break;
|
||||
case SC_DELETE:
|
||||
if (arg2&SCF_SHIFT)
|
||||
PsmCutToClipboard;
|
||||
PsmCutToClip;
|
||||
else {
|
||||
tmpn=psm.cur_note;
|
||||
psm.cur_note=tmpn->next;
|
||||
@@ -555,9 +555,9 @@ mo_got_msg:
|
||||
break;
|
||||
case SC_INS:
|
||||
if (arg2&SCF_SHIFT)
|
||||
PsmPasteClipboard;
|
||||
PsmPasteClip;
|
||||
else if (arg2&SCF_CTRL)
|
||||
PsmCopyToClipboard;
|
||||
PsmCopyToClip;
|
||||
break;
|
||||
case SC_F1:
|
||||
PsmPopMode;
|
||||
@@ -609,13 +609,13 @@ mo_got_msg:
|
||||
PsmPushMode(psm_octave);
|
||||
break;
|
||||
case CH_CTRLC:
|
||||
PsmCopyToClipboard;
|
||||
PsmCopyToClip;
|
||||
break;
|
||||
case CH_CTRLV:
|
||||
PsmPasteClipboard;
|
||||
PsmPasteClip;
|
||||
break;
|
||||
case CH_CTRLX:
|
||||
PsmCutToClipboard;
|
||||
PsmCutToClip;
|
||||
break;
|
||||
case '.':
|
||||
PsmMenu(psm_octave);
|
||||
@@ -786,7 +786,7 @@ mo_done:
|
||||
PutExcept;
|
||||
PsmPopMode;
|
||||
PsmSongDel(&psm.head);
|
||||
PsmSongDel(&psm.clipboard);
|
||||
PsmSongDel(&psm.clip);
|
||||
TempoDel(c);
|
||||
DCFill;
|
||||
DCDel(psm.dc2);
|
||||
|
||||
@@ -1 +1 @@
|
||||
MkDir("~/Span");
|
||||
DirMk("~/Span");
|
||||
|
||||
@@ -69,7 +69,7 @@ Bool SpanWrite(CMathODE *ode)
|
||||
U8 *name,*buf;
|
||||
I64 size;
|
||||
Bool res=FALSE,old_silent=Silent;
|
||||
MkDir("~/Span");
|
||||
DirMk("~/Span");
|
||||
Silent(old_silent);
|
||||
if (name=PopUpFileName("~/Span/Game.DATA")) {
|
||||
if (buf=SpanSave(ode,&size)) {
|
||||
@@ -115,7 +115,7 @@ U8 *SpanRead()
|
||||
{
|
||||
U8 *src=NULL,*name;
|
||||
Bool old_silent=Silent;
|
||||
MkDir("~/Span");
|
||||
DirMk("~/Span");
|
||||
Silent(old_silent);
|
||||
if (name=PopUpPickFile("~/Span")) {
|
||||
src=FileRead(name);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
if (!FileFind("~/TimeClock",,FUF_JUST_DIRS)) {
|
||||
MkDir("~/TimeClock");
|
||||
DirMk("~/TimeClock");
|
||||
DocClear;
|
||||
"After Loading, type $$GREEN$$PunchIn;$$FG$$, "
|
||||
"$$GREEN$$PunchOut;$$FG$$ or $$GREEN$$TimeRep;$$FG$$\n"
|
||||
|
||||
@@ -1,2 +1,2 @@
|
||||
MkDir("~/ToTheFront");
|
||||
DirMk("~/ToTheFront");
|
||||
|
||||
|
||||
@@ -71,13 +71,13 @@ U0 DrawHexes()
|
||||
}
|
||||
}
|
||||
|
||||
U0 MakeTerrain(U8 color,I64 cnt,I64 cluster_lo,I64 cluster_hi)
|
||||
U0 MakeTerrain(U8 color,I64 cnt,I64 clus_lo,I64 clus_hi)
|
||||
{
|
||||
I64 i,j,l,row,col;
|
||||
for (i=0;i<cnt;i++) {
|
||||
col=RandU32%map_cols;
|
||||
row=RandU32%map_rows;
|
||||
l=cluster_lo+RandU16%(cluster_hi-cluster_lo+1);
|
||||
l=clus_lo+RandU16%(clus_hi-clus_lo+1);
|
||||
for (j=0;j<l;j++) {
|
||||
terrain[row][col]=color;
|
||||
Toward(&row,&col,RandU16%6);
|
||||
|
||||
+1
-1
@@ -891,7 +891,7 @@ U0 PrsBinFile(CCmpCtrl *cc)
|
||||
U8 *buf,*st;
|
||||
if (cc->token!=TK_STR)
|
||||
LexExcept(cc,"Expecting string at ");
|
||||
st=DftExt(cc->cur_str,"BIN");
|
||||
st=ExtDft(cc->cur_str,"BIN");
|
||||
buf=FileRead(st,&size);
|
||||
Free(st);
|
||||
for (i=0;i<size;i++)
|
||||
|
||||
+6
-6
@@ -428,10 +428,10 @@ I64 Cmp(U8 *filename,U8 *map_name=NULL,U8 *out_name=NULL,U8 mapfile_drv_let=0)
|
||||
CAOTHeapGlblRef *tmphgr,*tmphgr1;
|
||||
CAOTHeapGlbl *tmphg,*tmphg1;
|
||||
|
||||
fbuf=DftExt(filename,"PRJ.Z");
|
||||
fbuf=ExtDft(filename,"PRJ.Z");
|
||||
fbuf2=MStrPrint("#include \"%s\"",fbuf);
|
||||
if (map_name)
|
||||
fbuf3=DftExt(map_name,"MAP.Z");
|
||||
fbuf3=ExtDft(map_name,"MAP.Z");
|
||||
|
||||
if (tmpaot=CmpBuf(fbuf2,fbuf3,&error_cnt,&warning_cnt,mapfile_drv_let)) {
|
||||
aot_U8s=tmpaot->aot_U8s;
|
||||
@@ -550,9 +550,9 @@ I64 Cmp(U8 *filename,U8 *map_name=NULL,U8 *out_name=NULL,U8 mapfile_drv_let=0)
|
||||
size-aot_U8s-sizeof(CBinFile));
|
||||
Free(fbuf2);
|
||||
if (out_name)
|
||||
fbuf2=DftExt(out_name,"BIN.Z");
|
||||
fbuf2=ExtDft(out_name,"BIN.Z");
|
||||
else
|
||||
fbuf2=ChgExt(fbuf,"BIN.Z");
|
||||
fbuf2=ExtChg(fbuf,"BIN.Z");
|
||||
FileWrite(fbuf2,bfh,size);
|
||||
Free(bfh);
|
||||
Free(tmpaot->buf);
|
||||
@@ -614,7 +614,7 @@ I64 ExePrint(U8 *fmt,...)
|
||||
I64 ExeFile(U8 *name,I64 ccf_flags=0)
|
||||
{//JIT Compile and execute a file.
|
||||
I64 res;
|
||||
U8 *name2=DftExt(name,"HC.Z"),
|
||||
U8 *name2=ExtDft(name,"HC.Z"),
|
||||
*st=MStrPrint("#include \"%s\";",name2);
|
||||
res=ExePutS(st,name,ccf_flags);
|
||||
Free(st);
|
||||
@@ -657,7 +657,7 @@ I64 ExePrint2(U8 *fmt,...)
|
||||
I64 ExeFile2(U8 *name,I64 ccf_flags=0)
|
||||
{//throws exceptions
|
||||
I64 res;
|
||||
U8 *name2=DftExt(name,"HC.Z"),*st=MStrPrint("#include \"%s\";",name2);
|
||||
U8 *name2=ExtDft(name,"HC.Z"),*st=MStrPrint("#include \"%s\";",name2);
|
||||
res=ExePutS2(st,name,ccf_flags);
|
||||
Free(st);
|
||||
Free(name2);
|
||||
|
||||
+1
-1
@@ -135,7 +135,7 @@ U8 *CmdLinePmt()
|
||||
"%8.6fs ans=0x%08X=%d\n",Fs->answer_time,Fs->answer,Fs->answer;
|
||||
Fs->new_answer=FALSE;
|
||||
}
|
||||
if (st=CurDir) {
|
||||
if (st=DirCur) {
|
||||
"%s",st;
|
||||
Free(st);
|
||||
}
|
||||
|
||||
Binary file not shown.
@@ -21,6 +21,7 @@ extern U0 StreamDir();
|
||||
public extern I64 StreamExePrint(U8 *fmt,...);
|
||||
public extern U0 StreamPrint(U8 *fmt,...);
|
||||
public extern Bool Trace(Bool val=ON);
|
||||
|
||||
#help_index "Compiler/Lex"
|
||||
#help_file "::/Doc/Lex"
|
||||
extern U0 ClassMemberLstDel(CHashClass *c);
|
||||
|
||||
+2
-2
@@ -698,7 +698,7 @@ lex_float_start:
|
||||
case KW_INCLUDE:
|
||||
if (Lex(cc)!=TK_STR)
|
||||
goto lex_end;
|
||||
fbuf=DftExt(cc->cur_str,"HC.Z");
|
||||
fbuf=ExtDft(cc->cur_str,"HC.Z");
|
||||
buf2=FileNameAbs(fbuf);
|
||||
Free(fbuf);
|
||||
if (Bt(&sys_run_level,RLf_DOC))
|
||||
@@ -1029,7 +1029,7 @@ lex_ifjit:
|
||||
if (Lex(cc)!=TK_STR)
|
||||
goto lex_end;
|
||||
tmph=CAlloc(sizeof(CHashSrcSym));
|
||||
fbuf=DftExt(cc->cur_str,"DD.Z");
|
||||
fbuf=ExtDft(cc->cur_str,"DD.Z");
|
||||
tmph->str=FileNameAbs(fbuf);
|
||||
Free(fbuf);
|
||||
tmph->type=HTT_HELP_FILE|HTF_PUBLIC;
|
||||
|
||||
@@ -219,17 +219,17 @@ Bool MyPutKey(I64 ch,I64 sc)
|
||||
return TRUE;
|
||||
case 'l':
|
||||
if (sc&SCF_KEY_DESC)
|
||||
KeyDescSet("Edit/Put Link to Cur Pos on Clipboard");
|
||||
KeyDescSet("Edit/Put Link to Cur Pos on Clip");
|
||||
else {
|
||||
ClipboardDel;
|
||||
ClipDel;
|
||||
st1=FileNameAbs(BIBLE_FILENAME);
|
||||
st2=FileNameAbs(DocPut->filename.name);
|
||||
if (!StrCmp(st1,st2)) {
|
||||
Free(st1);
|
||||
st1=BibleLine2Verse(DocPut->cur_entry->y+1,',');
|
||||
DocPrint(sys_clipboard_doc,"$$LK,\"BF:%s\"$$",st1);
|
||||
DocPrint(sys_clip_doc,"$$LK,\"BF:%s\"$$",st1);
|
||||
} else
|
||||
DocPrint(sys_clipboard_doc,"$$LK,\"FL:%s,%d\"$$",
|
||||
DocPrint(sys_clip_doc,"$$LK,\"FL:%s,%d\"$$",
|
||||
st2,DocPut->cur_entry->y+1);
|
||||
Free(st1);
|
||||
Free(st2);
|
||||
@@ -237,11 +237,11 @@ Bool MyPutKey(I64 ch,I64 sc)
|
||||
return TRUE;
|
||||
case 'L':
|
||||
if (sc&SCF_KEY_DESC)
|
||||
KeyDescSet("Edit/Place Anchor, Put Link to Clipboard");
|
||||
KeyDescSet("Edit/Place Anchor, Put Link to Clip");
|
||||
else {
|
||||
i=RandU32;
|
||||
ClipboardDel;
|
||||
DocPrint(sys_clipboard_doc,"$$LK,\"<TODO>\",A=\"FA:%s,ANC%d\"$$",
|
||||
ClipDel;
|
||||
DocPrint(sys_clip_doc,"$$LK,\"<TODO>\",A=\"FA:%s,ANC%d\"$$",
|
||||
DocPut->filename.name,i);
|
||||
"$$AN,\"<TODO>\",A=\"ANC%d\"$$",i;
|
||||
}
|
||||
|
||||
@@ -39,7 +39,7 @@ U0 StartUpTasks()
|
||||
|
||||
if (DrvIsWritable(':')) {
|
||||
DelTree("::/Tmp/ScrnShots");
|
||||
MkDir("::/Tmp/ScrnShots");
|
||||
DirMk("::/Tmp/ScrnShots");
|
||||
}
|
||||
|
||||
StartUpTasks;
|
||||
|
||||
@@ -1,16 +1,17 @@
|
||||
$MA,"Cd ",LM="Cd;Dir;\n"$$MA,"DrvC ",LM="Drv('C');\n"$$MA,"DrvD ",LM="Drv('D');\n"$$MA,"/ ",LM="Cd(\"/\");Dir;\n"$$MA,"TOS ",LM="Cd(\"/Home/TOS\");Dir;\n"$$MA,"Home ",LM="Cd(\"/Home\");Dir;\n"$$MA,"ChgDskT ",LM="ChgDsk('T');\n"$$MA,"MergeD ",LM="S2T(\"C:/*\",\"+r+S\");Merge(\"C:/*;!*/LineRep*\",\"D:/*;!*/LineRep*\",\"+r+d\");\n"$$MA,"MergeT ",LM="S2T(\"C:/*\",\"+r+S\");Merge(\"C:/*;!*/LineRep*\",\"T:/*;!*/LineRep*\",\"+r+d\");\n"$$MA,"D:/Wb ",LM="Cd(\"D:/Wb\");Dir;\n"$
|
||||
$MA,"MakeC ",LM="TOSBootHDIns('C');\n"$$MA+PU,"BootC ",LM="BootRAM(\"C:/Kernel.BIN.C\");"$$MA,"Regen ",LM="TOSRegen;\n"$$MA,"PreRegen",LM="TOSPreRegen;\n"$$MA,"MakeD ",LM="TOSBootHDIns('D');\n"$$MA+PU,"BootD ",LM="BootRAM(\"D:/Kernel.BIN.C\");"$$MA,"CopyDrv ",LM="TOSPmtAndCopyDrv;\n"$$MA,"MakeWeb ",LM="FreshenBlog;\n"$
|
||||
$MA,"Cd ",LM="Cd;Dir;\n"$$MA,"DrvC ",LM="Drv('C');\n"$$MA,"DrvD ",LM="Drv('D');\n"$$MA,"/ ",LM="Cd(\"/\");Dir;\n"$$MA,"TOS ",LM="Cd(\"/Home/TOS\");Dir;\n"$$MA,"Home ",LM="Cd(\"/Home\");Dir;\n"$$MA,"ChgDskT ",LM="DskChg('T');\n"$$MA,"MergeD ",LM="S2T(\"C:/*\",\"+r+S\");Merge(\"C:/*;!*/LineRep*\",\"D:/*;!*/LineRep*\",\"+r+d\");\n"$$MA,"MergeT ",LM="S2T(\"C:/*\",\"+r+S\");Merge(\"C:/*;!*/LineRep*\",\"T:/*;!*/LineRep*\",\"+r+d\");\n"$$MA,"D:/Wb ",LM="Cd(\"D:/Wb\");Dir;\n"$
|
||||
$MA,"MakeC ",LM="TOSBootHDIns('C');\n"$$MA+PU,"BootC ",LM="BootRAM(\"C:/Kernel.BIN.C\");"$$MA,"Regen ",LM="TOSRegen;\n"$$MA,"PreRegen",LM="TOSPreRegen;\n"$$MA,"MakeD ",LM="TOSBootHDIns('D');\n"$$MA+PU,"BootD ",LM="BootRAM(\"D:/Kernel.BIN.C\");"$$MA,"CopyDrv ",LM="TOSPmtAndCopyDrv;\n"$
|
||||
$MA,"Kernel ",LM="Cd(\"/Kernel\");Dir;\n"$$MA,"Compiler",LM="Cd(\"/Compiler\");Dir;\n"$$MA,"BlkDev ",LM="Cd(\"/Kernel/BlkDev\");Dir;\n"$$MA,"Mem ",LM="Cd(\"/Kernel/Mem\");Dir;\n"$$MA,"Serial ",LM="Cd(\"/Kernel/SerialDev\");Dir;\n"$$MA,"Bin ",LM="Cd(\"/Home/Sup1/Sup1Bin\");Dir;\n"$$MA,"HDAudio ",LM="Cd(\"/Home/Sup1/Sup1HDAudio\");Dir;\n"$$MA,"Examples",LM="Cd(\"/Home/Sup1/Sup1HDAudio/Examples\");Dir;\n"$$MA,"Dist ",LM="Cd(\"/Home/Sup1/Sup1Distro\");Dir;\n"$
|
||||
$MA,"Adam ",LM="Cd(\"/Adam\");Dir;\n"$$MA,"AutoComp",LM="Cd(\"/Adam/AutoComplete\");Dir;\n"$$MA,"Ctrls ",LM="Cd(\"/Adam/Ctrls\");Dir;\n"$$MA,"ABlkDev ",LM="Cd(\"/Adam/ABlkDev\");Dir;\n"$$MA,"DolDoc ",LM="Cd(\"/Adam/DolDoc\");Dir;\n"$$MA,"Gr ",LM="Cd(\"/Adam/Gr\");Dir;\n"$$MA,"God ",LM="Cd(\"/Adam/God\");Dir;\n"$$MA,"Snd ",LM="Cd(\"/Adam/Snd\");Dir;\n"$$MA,"Boot ",LM="Cd(\"/Adam/Opt/Boot\");Dir;\n"$$MA,"Utils ",LM="Cd(\"/Adam/Opt/Utils\");Dir;\n"$
|
||||
$LK+X,"ChgLog ",A="FI:::/Doc/ChgLog.DD"$$MA,"Blog ",LM="Blog;\n"$$MA,"EdGod ",LM="Ed(\"D:/Home/God.DD\");\n"$$MA,"BlogDir ",LM="Cd(\"/Home/Web/TAD/BlogDir\");Dir;\n"$$MA,"Partial ",LM="FreshenBlog;\n"$$MA,"CodeWalk",LM="CodeWalkThru;\n"$$MA,"TOSTheme",LM="TOSTheme;\n"$$MA,"Videos ",LM="Cd(\"/Home/Sup1/Sup1Videos\");Dir;\n"$
|
||||
$MA,"Web ",LM="Cd(\"/Home/Web\");Dir;\n"$$MA,"TAD ",LM="Cd(\"/Home/Web/TAD\");Dir;\n"$$MA,"DLC ",LM="Cd(\"/Home/Web/DLC\");Dir;\n"$$MA,"AppStore",LM="Cd(\"/Home/Web/AppStore\");Dir;\n"$$MA,"Sup1 ",LM="Cd(\"/Home/Sup1\");Dir;\n"$$MA,"Blog ",LM="Cd(\"/Home/Sup1/Sup1Blog\");Dir;\n"$$MA,"Code ",LM="Cd(\"/Home/Sup1/Sup1CodeScraps\");Dir;\n"$$MA,"Games ",LM="Cd(\"/Home/Sup1/Sup1Games\");Dir;\n"$$MA,"Graphics",LM="Cd(\"/Home/Sup1/Sup1Graphics\");Dir;\n"$$MA,"Utils ",LM="Cd(\"/Home/Sup1/Sup1Utils\");Dir;\n"$
|
||||
$MA-X+PU,"EdHymns ",LM="#include \"::/Apps/Psalmody/Load\";Psalmody(\"~/Sup1/Sup1Hymns\");"$$MA-X+PU,"EdSongs ",LM="#include \"::/Apps/Psalmody/Load\";Psalmody(\"~/Sup1/Sup1Songs\");"$$MA,"SongsIn ",LM="TOSSongsIn;\n"$$MA,"SongsOut",LM="TOSSongsOut;\n"$$MA,"HomeIn ",LM="TOSHomeIn;\n"$$MA,"HomeOut ",LM="TOSHomeOut;\n"$$MA,"MakeWeb ",LM="FreshenBlog;\n"$
|
||||
$MA,"Web ",LM="Cd(\"/Home/Web\");Dir;\n"$$MA,"TAD ",LM="Cd(\"/Home/Web/TAD\");Dir;\n"$$MA,"AppStore",LM="Cd(\"/Home/Web/AppStore\");Dir;\n"$$MA,"Sup1 ",LM="Cd(\"/Home/Sup1\");Dir;\n"$$MA,"Blog ",LM="Cd(\"/Home/Sup1/Sup1Blog\");Dir;\n"$$MA,"Code ",LM="Cd(\"/Home/Sup1/Sup1CodeScraps\");Dir;\n"$$MA,"Games ",LM="Cd(\"/Home/Sup1/Sup1Games\");Dir;\n"$$MA,"Graphics",LM="Cd(\"/Home/Sup1/Sup1Graphics\");Dir;\n"$$MA,"Utils ",LM="Cd(\"/Home/Sup1/Sup1Utils\");Dir;\n"$
|
||||
$MA,"Apps ",LM="Cd(\"/Apps\");Dir;\n"$$MA,"Budget ",LM="Cd(\"/Apps/Budget\");Dir;\n"$$MA,"GrModels",LM="Cd(\"/Apps/GrModels\");Dir;\n"$$MA,"KeepAway",LM="Cd(\"/Apps/KeepAway\");Dir;\n"$$MA,"Logic ",LM="Cd(\"/Apps/Logic\");Dir;\n"$$MA,"Psalmody",LM="Cd(\"/Apps/Psalmody\");Dir;\n"$$MA,"Span ",LM="Cd(\"/Apps/Span\");Dir;\n"$$MA,"Strut ",LM="Cd(\"/Apps/Strut\");Dir;\n"$$MA,"TimeClk ",LM="Cd(\"/Apps/TimeClock\");Dir;\n"$
|
||||
$MA,"Titan ",LM="Cd(\"/Apps/Titanium\");Dir;\n"$$MA,"ToTheFrt",LM="Cd(\"/Apps/ToTheFront\");Dir;\n"$$MA,"Vocab ",LM="Cd(\"/Apps/Vocabulary\");Dir;\n"$$MA,"XCaliber",LM="Cd(\"/Apps/X-Caliber\");Dir;\n"$$MA,"Books1 ",LM="Cd(\"/Home/Books1\");Dir;\n"$$MA,"Books2 ",LM="Cd(\"/Home/Books2\");Dir;\n"$$MA,"Hymns ",LM="Cd(\"/Home/Sup1/Sup1Hymns\");Dir;\n"$$MA,"Songs ",LM="Cd(\"/Home/Sup1/Sup1Songs\");Dir;\n"$
|
||||
$MA,"Demo ",LM="Cd(\"/Demo\");Dir;\n"$$MA,"AcctEmpl",LM="Cd(\"/Demo/AcctExample\");Dir;\n"$$MA,"Asm ",LM="Cd(\"/Demo/Asm\");Dir;\n"$$MA,"DocDoc ",LM="Cd(\"/Demo/DolDoc\");Dir;\n"$$MA,"Dsk ",LM="Cd(\"/Demo/Dsk\");Dir;\n"$$MA,"Games ",LM="Cd(\"/Demo/Games\");Dir;\n"$$MA,"Graphics",LM="Cd(\"/Demo/Graphics\");Dir;\n"$$MA,"InFile ",LM="Cd(\"/Demo/InFile\");Dir;\n"$$MA,"Lectures",LM="Cd(\"/Demo/Lectures\");Dir;\n"$$MA,"MultCore",LM="Cd(\"/Demo/MultiCore\");Dir;\n"$
|
||||
$MA,"RevFile ",LM="Cd(\"/Demo/RevFileDemo\");Dir;\n"$$MA,"Snd ",LM="Cd(\"/Demo/Snd\");Dir;\n"$$MA,"SortFile",LM="Cd(\"/Demo/SortFileDemo\");Dir;\n"$$MA,"Template",LM="Cd(\"/Demo/Templates\");Dir;\n"$$MA,"HtmlTXT ",LM="Cd(\"/Demo/ToHtmlToTXTDemo\");Dir;\n"$$MA,"WebLog ",LM="Cd(\"/Demo/WebLogDemo\");Dir;\n"$$MA,"Stadium ",LM="Cd(\"/Demo/Games/Stadium\");Dir;\n"$
|
||||
$MA,"Doc ",LM="Cd(\"/Doc\");Dir;\n"$$MA,"Misc ",LM="Cd(\"/Misc\");Dir;\n"$$MA,"Tour ",LM="Cd(\"/Misc/Tour\");Dir;\n"$$MA,"Tmp ",LM="Cd(\"/Tmp\");Dir;\n"$$MA,"ScrnShot",LM="Cd(\"/Tmp/ScrnShots\");Dir;\n"$$MA,"DelScrSt",LM="Del(\"D:/Tmp/*.SND\");DelTree(\"D:/Tmp/ScrnShots\");MkDir(\"D:/Tmp/ScrnShots\");Del(\"C:/Tmp/*.SND\");DelTree(\"C:/Tmp/ScrnShots\");MkDir(\"C:/Tmp/ScrnShots\");\n"$$MA,"0000Boot",LM="Cd(\"/0000Boot\");Dir;\n"$$MA,"Linux ",LM="Cd(\"/Linux\");Dir;\n"$
|
||||
$MA,"Doc ",LM="Cd(\"/Doc\");Dir;\n"$$MA,"Misc ",LM="Cd(\"/Misc\");Dir;\n"$$MA,"Tour ",LM="Cd(\"/Misc/Tour\");Dir;\n"$$MA,"Tmp ",LM="Cd(\"/Tmp\");Dir;\n"$$MA,"ScrnShot",LM="Cd(\"/Tmp/ScrnShots\");Dir;\n"$$MA,"DelScrSt",LM="Del(\"D:/Tmp/*.SND\");DelTree(\"D:/Tmp/ScrnShots\");DirMk(\"D:/Tmp/ScrnShots\");Del(\"C:/Tmp/*.SND\");DelTree(\"C:/Tmp/ScrnShots\");DirMk(\"C:/Tmp/ScrnShots\");\n"$$MA,"0000Boot",LM="Cd(\"/0000Boot\");Dir;\n"$$MA,"Linux ",LM="Cd(\"/Linux\");Dir;\n"$
|
||||
$MA,"LinxDict",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/LinuxDict.TXT**\\\");\");\n"$$MA,"August ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/AugustWords.TXT**\\\");\");\n"$$MA,"Happy ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/HappyWords.TXT*\\\");\");\n"$$MA,"Yiddish ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/Yiddish.TXT*\\\");\");\n"$$MA,"Bible ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/BibleWords.TXT*\\\");\");\n"$$MA,"Huck ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/HuckWords.TXT*\\\");\");\n"$$MA,"Ingreds ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/Ingredients.TXT*\\\");\");\n"$$MA,"Chess ",LM="Adam(\"GodInit(\\\"~/Sup1/Sup1Words/Chess.DD*\\\");\");\n"$$MA,"Words ",LM="Cd(\"/Home/Sup1/Sup1Words\");Dir;\n"$
|
||||
$MA,"MakeStd ",LM="MakeStdDistro;MkDir(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSCD.ISO\");\n"$$MA,"MakeStRS",LM="MakeStdRedSeaDistro;MkDir(\"D:/Wb\");Move(TOS_ISO_C_NAME,\"D:/Wb/TempleOSCDRS.ISO\");\n"$$MA,"MakeUlt ",LM="MakeUltraDistro;MkDir(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSUltra.ISO\");\n"$$MA,"MakeUtRS",LM="MakeUltraRedSeaDistro;MkDir(\"D:/Wb\");Move(TOS_ISO_C_NAME,\"D:/Wb/TempleOSUltraRS.ISO\");\n"$$MA,"MakeStaf",LM="MakeStaffDistro;MkDir(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSStaff.ISO\");\n"$$MA,"MakeDbg ",LM="MakeDbgDistro;MkDir(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSDbg.ISO\");\n"$
|
||||
$MA,"MakeStd ",LM="MakeStdDistro;DirMk(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSCD.ISO\");\n"$$MA,"MakeStRS",LM="MakeStdRedSeaDistro;DirMk(\"D:/Wb\");Move(TOS_ISO_C_NAME,\"D:/Wb/TempleOSCDRS.ISO\");\n"$$MA,"MakeUlt ",LM="MakeUltraDistro;DirMk(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSUltra.ISO\");\n"$$MA,"MakeUtRS",LM="MakeUltraRedSeaDistro;DirMk(\"D:/Wb\");Move(TOS_ISO_C_NAME,\"D:/Wb/TempleOSUltraRS.ISO\");\n"$$MA,"MakeStaf",LM="MakeStaffDistro;DirMk(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSStaff.ISO\");\n"$$MA,"MakeDbg ",LM="MakeDbgDistro;DirMk(\"D:/Wb\");Move(TOS_ISO_NAME,\"D:/Wb/TempleOSDbg.ISO\");\n"$
|
||||
$MA,"BurnStd ",LM="MakeStdDistro;DVDImageWrite('T',TOS_ISO_NAME);\n"$$MA,"BurnStRS",LM="MakeStdRedSeaDistro;DVDImageWrite('T',TOS_ISO_C_NAME);\n"$$MA,"BurnUlt ",LM="MakeUltraDistro;DVDImageWrite('T',TOS_ISO_NAME);\n"$$MA,"BurnUtRS",LM="MakeUltraRedSeaDistro;DVDImageWrite('T',TOS_ISO_C_NAME);\n"$$MA,"BurnStaf",LM="MakeStaffDistro;DVDImageWrite('T',TOS_ISO_NAME);\n"$$MA,"BurnDbg ",LM="MakeDbgDistro;DVDImageWrite('T',TOS_ISO_NAME);\n"$
|
||||
|
||||
|
||||
|
||||
@@ -29,7 +29,7 @@ $WW,1$$FG,5$$TX+CX,"TODO"$$FG$
|
||||
* Cannot include ':' in $LK,"Document Links",A="FF:::/Adam/DolDoc/DocLink.HC,AD"$ search string.
|
||||
* $$DA fixed width string: <Del> or <BACKSPACE> permanently shortens.
|
||||
|
||||
* 11/19/16 editor took long time after copying old testament onto clipboard and exiting.
|
||||
* 11/19/16 editor took long time after copying old testament onto clip and exiting.
|
||||
|
||||
* Nestled switch() start/end?
|
||||
|
||||
@@ -181,7 +181,7 @@ $FG,5$$TX+CX,"Bugs? Not really sure."$$FG$
|
||||
|
||||
* 4/13/14 Strut or RawHide crashed when $LK,"sys_var_init_flag",A="MN:sys_var_init_flag"$ was set during testsuite. Perhaps, floodfill?
|
||||
|
||||
* $LK,"ChkDsk",A="MN:ChkDsk"$ alloc unalloced. I don't know if I fixed this.
|
||||
* $LK,"DskChk",A="MN:DskChk"$ alloc unalloced. I don't know if I fixed this.
|
||||
|
||||
* 1/?/2015,8/10/2015 Macro sel in Menu did not go to shell? No, I think just <CTRL-m> twice. Not a bug.
|
||||
|
||||
@@ -453,7 +453,6 @@ I made dis $HC,"<center><img src=\"http://i.imgur.com/cZKkxTX.jpg\" width=\"640\
|
||||
NIST Beacon $HC,"<center><img src=\"http://www.nist.gov/itl/csd/ct/images/beacon_architecture_2013.jpg\" width=\"550\" height=\"278\" alt=\"\"></center>"$
|
||||
Purple Frog $HC,"<center><img src=\"https://s-media-cache-ak0.pinimg.com/736x/fb/08/2a/fb082a53bd798f5957a474ff9095e6d4.jpg\" width=\"640\" height=\"420\" alt=\"\"></center>"$
|
||||
Casino (Dog) $HC,"<center><img src=\"http://www.templeos.org/images/Dog1855x1056.jpg\" width=\"640\" height=\"364\" alt=\"\"></center>"$
|
||||
Dianna's Cross $HC,"<iframe src=\"https://www.facebook.com/plugins/post.php?href=https%3A%2F%2Fwww.facebook.com%2Fthephysicsgirl%2Fposts%2F1133902680027666&width=500\" width=\"500\" height=\"671\" style=\"border:none;overflow:hidden\" scrolling=\"no\" frameborder=\"0\" allowTransparency=\"true\"></iframe>"$
|
||||
|
||||
|
||||
$TX,"SimStructure",HTML="http://www.templeos.org/files/SimStrSetUp.zip"$
|
||||
|
||||
@@ -2,7 +2,7 @@ $TR-UL,"Adam"$
|
||||
$ID,2$$TR,"SysMsgFlags"$
|
||||
$ID,2$sys_msg_flags[0]=0xFF;
|
||||
$ID,-2$$TR,"SysRegVer"$
|
||||
$ID,2$registry_version=5.010;
|
||||
$ID,2$registry_version=5.020;
|
||||
$ID,-2$$TR,"InsReg"$
|
||||
$ID,2$#help_index "Registry/Install Registration"
|
||||
MemSet(&ins_reg,0,sizeof(CInsReg));
|
||||
@@ -31,7 +31,7 @@ $ID,2$F64 best_score=4.9425;
|
||||
$ID,-2$$TR,"TOSNIST"$
|
||||
$ID,2$I64 tos_nist_offset=-8049;
|
||||
$ID,-2$$TR,"BlackDiamond"$
|
||||
$ID,2$I64 best_score=1;
|
||||
$ID,2$I64 best_score=23;
|
||||
$ID,-2$$TR,"DunGen"$
|
||||
$ID,2$F64 best_score=20.5295;
|
||||
$ID,-2$$TR,"CastleFrankenstein"$
|
||||
@@ -48,27 +48,22 @@ $ID,-2$$TR,"KeepAway"$
|
||||
$ID,2$I64 best_score0=68,best_score1=30;
|
||||
$ID,-2$$TR,"Wenceslas"$
|
||||
$ID,2$F64 best_score=43.9944;
|
||||
$ID,-2$$TR,"BomberGolf"$
|
||||
$ID,2$I64 best_score=175;
|
||||
$ID,-2$$TR,"OSTestSuite"$
|
||||
$ID,2$progress1_tf=0.000;progress2_tf=0.000;
|
||||
progress3_tf=0.000;progress4_tf=228.734;
|
||||
$ID,-2$$TR,"Titanium"$
|
||||
$ID,2$I64 best_score=16469;
|
||||
$ID,-2$$TR,"XCaliber"$
|
||||
$ID,2$I64 best_score=90;
|
||||
I64 msg_flags=2;
|
||||
$ID,-2$$TR,"Talons"$
|
||||
$ID,2$F64 best_score=9999.0000;
|
||||
$ID,-2$$TR,"BomberGolf"$
|
||||
$ID,2$I64 best_score=175;
|
||||
$ID,-2$$TR,"Titanium"$
|
||||
$ID,2$I64 best_score=16469;
|
||||
$ID,-2$$TR,"TOSRegen"$
|
||||
$ID,2$progress1_tf=0.000;progress2_tf=0.000;
|
||||
progress3_tf=0.000;progress4_tf=192.371;
|
||||
progress3_tf=0.000;progress4_tf=196.256;
|
||||
$ID,-2$$ID,-2$$TR,"Once"$
|
||||
$ID,2$$TR,"Adam"$
|
||||
$ID,2$$ID,-2$$TR,"User"$
|
||||
$ID,2$$ID,-2$$ID,-2$$TR,"DemoCompany"$
|
||||
$ID,2$$TR,"Game1"$
|
||||
$ID,2$F64 best_score=1735.08564;
|
||||
$TR,"SimpleVal"$
|
||||
$ID,2$1236;
|
||||
$ID,-2$$ID,-2$$ID,-2$
|
||||
$ID,2$$ID,-2$$ID,-2$
|
||||
@@ -8,7 +8,7 @@ public U8 *BlogLocalDir(CDate cdt=0)
|
||||
Date2Struct(&ds,cdt);
|
||||
StrPrint(dir,BLOG_LOCAL_BASE "/%d%Z",ds.year,ds.mon-1,"ST_MONTHS");
|
||||
if (!FileFind(dir,,FUF_JUST_DIRS))
|
||||
MkDir(dir);
|
||||
DirMk(dir);
|
||||
return dir;
|
||||
}
|
||||
|
||||
@@ -89,11 +89,11 @@ public U0 BlogScrnShot()
|
||||
|
||||
public U0 FreshenBlog()
|
||||
{//Regen html files for D:/Home/Web.
|
||||
MkDir("D:/Wb");
|
||||
MkDir("D:/Wb/Home");
|
||||
MkDir("D:/Wb/Home/Web");
|
||||
MkDir("D:/Wb/Home/Web/" INS_REG_PERSONAL_INITIALS);
|
||||
MkDir("D:/Wb/Home/Web/" INS_REG_PERSONAL_INITIALS "/BlogDir");
|
||||
DirMk("D:/Wb");
|
||||
DirMk("D:/Wb/Home");
|
||||
DirMk("D:/Wb/Home/Web");
|
||||
DirMk("D:/Wb/Home/Web/" INS_REG_PERSONAL_INITIALS);
|
||||
DirMk("D:/Wb/Home/Web/" INS_REG_PERSONAL_INITIALS "/BlogDir");
|
||||
|
||||
FreshenWebDir("/Home/Web");
|
||||
FreshenWebDir("/Home/Web/" INS_REG_PERSONAL_INITIALS);
|
||||
|
||||
@@ -54,14 +54,14 @@ U0 TOSInit()
|
||||
#define TOS_ISO_NAME "B:/TempleOSCD.ISO"
|
||||
#define TOS_ISO_C_NAME "B:/TempleOSCD.ISO.C"
|
||||
#define TOS_DISTRO_DIR "B:/Distro"
|
||||
#define CFG_OPTS "StaffMode\nAutoMountIDE\nCT\n"
|
||||
#define CFG_DBG_OPTS "StaffMode\nAutoMountIDE\nCT"\
|
||||
#define CFG_OPTS "StaffMode\nMountIDEAuto\nCT\n"
|
||||
#define CFG_DBG_OPTS "StaffMode\nMountIDEAuto\nCT"\
|
||||
"HeapInit\n130\nMemInit\n131\nVarInit\n132\n\n"
|
||||
#define CFG_DBGZ_OPTS "StaffMode\nAutoMountIDE\nCT"\
|
||||
#define CFG_DBGZ_OPTS "StaffMode\nMountIDEAuto\nCT"\
|
||||
"HeapInit\n0\nMemInit\n0\nVarInit\n0\n\n"
|
||||
#define TOS_CFG "\n" CFG_RAM_DRVS CFG_DVD_DRVS CFG_HARD_DRVS "\n"\
|
||||
CFG_DSK_CACHE CFG_OPTS
|
||||
#define TOS_DVD_CFG "TB\n0x20000\nT \n\n\nStaffMode\nAutoMountIDE\nCT\n"
|
||||
#define TOS_DVD_CFG "TB\n0x20000\nT \n\n\nStaffMode\nMountIDEAuto\nCT\n"
|
||||
#define TOS_DVD_DBG_CFG "A" CFG_DBG_DISTRO\
|
||||
"B\nScale2Mem(2048,0x40000)\n\n\n"\
|
||||
"NoMP\nTextMode\nDontProbe\nDbgDistro\n"\
|
||||
|
||||
@@ -63,9 +63,9 @@ U0 DistroSongsPrep(U8 threshold='7')
|
||||
CDoc *doc;
|
||||
CDocEntry *doc_e;
|
||||
CDirEntry *tmpde=FilesFind("/Home/Sup1/Sup1Hymns/*.HC*",
|
||||
FUF_CLUSTER_ORDER),*tmpde1=tmpde;
|
||||
FUF_CLUS_ORDER),*tmpde1=tmpde;
|
||||
DelTree("/Apps/Psalmody/Examples");
|
||||
MkDir("/Apps/Psalmody/Examples");
|
||||
DirMk("/Apps/Psalmody/Examples");
|
||||
while (tmpde) {
|
||||
doc=DocRead(tmpde->full_name);
|
||||
doc_e=doc->head.next;
|
||||
@@ -88,8 +88,8 @@ U0 DistroPrep()
|
||||
DistroSongsPrep;
|
||||
|
||||
DelTree("/Tmp");
|
||||
MkDir("/Tmp");
|
||||
MkDir("/Tmp/ScrnShots");
|
||||
DirMk("/Tmp");
|
||||
DirMk("/Tmp/ScrnShots");
|
||||
|
||||
Touch("/PersonalMenu.DD.Z","+T");
|
||||
Touch("/Home/PersonalMenu.DD.Z","+T");
|
||||
@@ -130,19 +130,19 @@ U0 DbgDistroFilePrep()
|
||||
bd=Let2BlkDev('A');
|
||||
Fmt('A',,FALSE,FSt_REDSEA);
|
||||
|
||||
MkDir("A:/Compiler");
|
||||
DirMk("A:/Compiler");
|
||||
Copy("C:/Compiler/Compiler.BIN.Z", "A:/Compiler");
|
||||
Copy("C:/Compiler/OpCodes.DD.Z", "A:/Compiler");
|
||||
Copy("C:/Compiler/CompilerA.HH.Z", "A:/Compiler");
|
||||
Copy("C:/Compiler/CompilerB.HH.Z", "A:/Compiler");
|
||||
|
||||
MkDir("A:/Kernel");
|
||||
DirMk("A:/Kernel");
|
||||
Copy("C:/Kernel/*.HH*", "A:/Kernel");
|
||||
CopyTree("C:/Kernel/BlkDev", "A:/Kernel/BlkDev");
|
||||
|
||||
Copy("C:/Home/Sup1/Sup1Distro/DbgStartOS.HC.Z","A:/StartOS.HC.Z");
|
||||
|
||||
MkDir("A:/Adam");
|
||||
DirMk("A:/Adam");
|
||||
Copy("C:/Home/Sup1/Sup1Distro/DbgMakeAdam.HC.Z","A:/Adam/MakeAdam.HC.Z");
|
||||
Copy("C:/Home/Sup1/Sup1Distro/DbgMount.HC.Z","A:/Adam");
|
||||
Copy("C:/Adam/AExts.HC.Z", "A:/Adam");
|
||||
@@ -189,7 +189,6 @@ I64 MakeLineRepFile()
|
||||
U8 *st;
|
||||
CDoc *doc;
|
||||
I64 res,official;
|
||||
CDocEntry *tree_branch,*start_indent,*end_indent;
|
||||
|
||||
DocClear;
|
||||
Drv('C');
|
||||
@@ -219,15 +218,10 @@ I64 MakeLineRepFile()
|
||||
CopyTree("B:/TOS/TOS","C:/Home");
|
||||
DelTree("B:/TOS/TOS");
|
||||
|
||||
doc=DocRead("C:/Adam/ADefine.HC.Z");
|
||||
DocTreeFind(doc,"LineRep",&tree_branch,&start_indent,&end_indent);
|
||||
DocCut(doc,start_indent->next,end_indent->last);
|
||||
doc->cur_entry=start_indent->next;
|
||||
doc->cur_col=0;
|
||||
DocPrint(doc,"DefinePrint(\"DD_TEMPLEOS_LOC\",\"%,d\");\n",res);
|
||||
DocPrint(doc,"DefinePrint(\"DD_TEMPLEOS_LOC_OFFICIAL\",\"%,d\");\n",official);
|
||||
DocWrite(doc);
|
||||
DocDel(doc);
|
||||
DocTreeFWrite("C:/Adam/ADefine.HC.Z","LineRep",
|
||||
"DefinePrint(\"DD_TEMPLEOS_LOC\",\"%,d\");\n",res);
|
||||
DocTreeFAppend("C:/Adam/ADefine.HC.Z","LineRep",
|
||||
"DefinePrint(\"DD_TEMPLEOS_LOC_OFFICIAL\",\"%,d\");\n",official);
|
||||
|
||||
DefinePrint("DD_TEMPLEOS_LOC","%,d",res);
|
||||
DefinePrint("DD_TEMPLEOS_LOC_OFFICIAL","%,d",official);
|
||||
@@ -256,7 +250,7 @@ U0 MakeStaffDistro()
|
||||
ISO9660ISO(TOS_ISO_NAME,TOS_DISTRO_DIR "/*",,
|
||||
TOS_DISTRO_DIR BOOT_DIR_KERNEL_BIN_C);
|
||||
DefinePrint("DD_TEMPLEOS_STAFF_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - T.S. Company Internal Distro (%0.1fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - T.S. Company Internal Distro (%0.1fMB)",
|
||||
0.1*(10*Size(TOS_ISO_NAME,"+s")/1024/1024));
|
||||
Drv('C');
|
||||
}
|
||||
@@ -272,7 +266,7 @@ U0 DbgDistroPrep()
|
||||
DelTree(TOS_DISTRO_DIR);
|
||||
CopyTree("C:/",TOS_DISTRO_DIR "/");
|
||||
DelTree(TOS_DISTRO_DIR "/Home");
|
||||
MkDir(TOS_DISTRO_DIR "/Home");
|
||||
DirMk(TOS_DISTRO_DIR "/Home");
|
||||
Del(TOS_DISTRO_DIR "/" KERNEL_BIN_C);
|
||||
Del(TOS_DISTRO_DIR BOOT_DIR "/OldMBR.BIN.C");
|
||||
Del(TOS_DISTRO_DIR BOOT_DIR "/BootMHD2.BIN.C");
|
||||
@@ -283,7 +277,7 @@ U0 MakeDbgDistro()
|
||||
ISO9660ISO(TOS_ISO_NAME,TOS_DISTRO_DIR "/*",,
|
||||
TOS_DISTRO_DIR BOOT_DIR_KERNEL_BIN_C);
|
||||
DefinePrint("DD_TEMPLEOS_DBG_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - Debug Distro (%0.1fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - Debug Distro (%0.1fMB)",
|
||||
0.1*(10*Size(TOS_ISO_NAME,"+s")/1024/1024));
|
||||
Drv('C');
|
||||
}
|
||||
@@ -298,7 +292,7 @@ U0 StdDistroPrep()
|
||||
DelTree(TOS_DISTRO_DIR);
|
||||
CopyTree("C:/",TOS_DISTRO_DIR "/");
|
||||
DelTree(TOS_DISTRO_DIR "/Home");
|
||||
MkDir(TOS_DISTRO_DIR "/Home");
|
||||
DirMk(TOS_DISTRO_DIR "/Home");
|
||||
Del(TOS_DISTRO_DIR "/" KERNEL_BIN_C);
|
||||
Del(TOS_DISTRO_DIR BOOT_DIR "/OldMBR.BIN.C");
|
||||
Del(TOS_DISTRO_DIR BOOT_DIR "/BootMHD2.BIN.C");
|
||||
@@ -309,7 +303,7 @@ U0 MakeStdDistro()
|
||||
ISO9660ISO(TOS_ISO_NAME,TOS_DISTRO_DIR "/*",,
|
||||
TOS_DISTRO_DIR BOOT_DIR_KERNEL_BIN_C);
|
||||
DefinePrint("DD_TEMPLEOSCD_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - Standard Distro (%0.1fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - Standard Distro (%0.1fMB)",
|
||||
0.1*(10*Size(TOS_ISO_NAME,"+s")/1024/1024));
|
||||
Drv('C');
|
||||
}
|
||||
@@ -318,7 +312,7 @@ U0 MakeStdRedSeaDistro()
|
||||
StdDistroPrep;
|
||||
RedSeaISO(TOS_ISO_C_NAME,TOS_DISTRO_DIR,TOS_DISTRO_DIR BOOT_DIR_KERNEL_BIN_C);
|
||||
DefinePrint("DD_TEMPLEOSCD_RS_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - Standard RedSea Distro (%0.1fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - Standard RedSea Distro (%0.1fMB)",
|
||||
0.1*(10*Size(TOS_ISO_C_NAME,"+s")/1024/1024));
|
||||
Drv('C');
|
||||
}
|
||||
@@ -333,7 +327,7 @@ U0 UltraDistroPrep()
|
||||
Del(TOS_DISTRO_DIR "/Misc/Bible.TXT.Z");
|
||||
|
||||
DelTree(TOS_DISTRO_DIR "/Apps");
|
||||
MkDir(TOS_DISTRO_DIR "/Apps");
|
||||
DirMk(TOS_DISTRO_DIR "/Apps");
|
||||
DelTree(TOS_DISTRO_DIR "/Demo");
|
||||
DelTree(TOS_DISTRO_DIR "/Misc/Tour");
|
||||
Del(TOS_DISTRO_DIR "/" KERNEL_BIN_C);
|
||||
@@ -351,7 +345,7 @@ U0 MakeUltraDistro()
|
||||
ISO9660ISO(TOS_ISO_NAME,TOS_DISTRO_DIR "/*",,
|
||||
TOS_DISTRO_DIR BOOT_DIR_KERNEL_BIN_C);
|
||||
DefinePrint("DD_TEMPLEOS_ULTRA_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - UltraSmall Distro (%0.2fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - UltraSmall Distro (%0.2fMB)",
|
||||
0.01*(100*Size(TOS_ISO_NAME,"+s")/1024/1024));
|
||||
Drv('C');
|
||||
}
|
||||
@@ -360,7 +354,7 @@ U0 MakeUltraRedSeaDistro()
|
||||
UltraDistroPrep;
|
||||
RedSeaISO(TOS_ISO_C_NAME,TOS_DISTRO_DIR,TOS_DISTRO_DIR BOOT_DIR_KERNEL_BIN_C);
|
||||
DefinePrint("DD_TEMPLEOS_ULTRA_RS_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - UltraSmall RedSea Distro (%0.2fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - UltraSmall RedSea Distro (%0.2fMB)",
|
||||
0.01*(100*Size(TOS_ISO_C_NAME,"+s")/1024/1024));
|
||||
Drv('C');
|
||||
}
|
||||
@@ -370,28 +364,28 @@ U0 UpdateISODocDefines()
|
||||
try {
|
||||
#if MAKE_STD
|
||||
DefinePrint("DD_TEMPLEOSCD_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - Standard Distro (%0.1fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - Standard Distro (%0.1fMB)",
|
||||
0.1*(10*Size("D:/Wb/TempleOSCD.ISO","+s")/1024/1024));
|
||||
DefinePrint("DD_TEMPLEOSCD_K_SIZE",
|
||||
"%dKB",Size("D:/Wb/TempleOSCD.ISO","+s")/1024);
|
||||
#endif
|
||||
#if MAKE_STD_RS
|
||||
DefinePrint("DD_TEMPLEOSCD_RS_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - Standard RedSea Distro (%0.1fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - Standard RedSea Distro (%0.1fMB)",
|
||||
0.1*(10*Size("D:/Wb/TempleOSCDRS.ISO","+s")/1024/1024));
|
||||
DefinePrint("DD_TEMPLEOSCD_RS_K_SIZE",
|
||||
"%dKB",Size("D:/Wb/TempleOSCDRS.ISO","+s")/1024);
|
||||
#endif
|
||||
#if MAKE_ULTRA
|
||||
DefinePrint("DD_TEMPLEOS_ULTRA_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - UltraSmall Distro (%0.2fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - UltraSmall Distro (%0.2fMB)",
|
||||
0.01*(100*Size("D:/Wb/TempleOSUltra.ISO","+s")/1024/1024));
|
||||
DefinePrint("DD_TEMPLEOS_ULTRA_K_SIZE",
|
||||
"%dKB",Size("D:/Wb/TempleOSUltra.ISO","+s")/1024);
|
||||
#endif
|
||||
#if MAKE_ULTRA_RS
|
||||
DefinePrint("DD_TEMPLEOS_ULTRA_RS_SIZE",
|
||||
"Download $TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$ - UltraSmall RedSea Distro (%0.2fMB)",
|
||||
"Download $TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$ - UltraSmall RedSea Distro (%0.2fMB)",
|
||||
0.01*(100*Size("D:/Wb/TempleOSUltraRS.ISO","+s")/1024/1024));
|
||||
DefinePrint("DD_TEMPLEOS_ULTRA_RS_K_SIZE",
|
||||
"%dKB",Size("D:/Wb/TempleOSUltraRS.ISO","+s")/1024);
|
||||
@@ -452,11 +446,11 @@ U0 TOSRegen3()
|
||||
tos_progress_t0=tS;
|
||||
RegExe("TempleOS/TOSRegen");
|
||||
|
||||
TOSProgress("ChkDsk All");
|
||||
TOSProgress("DskChk All");
|
||||
AutoComplete;
|
||||
WinBorder;
|
||||
WinMax;
|
||||
ChkAll;
|
||||
DskChkAll;
|
||||
|
||||
TOSProgress("Make LineRep");
|
||||
MakeLineRepFile;
|
||||
@@ -554,9 +548,9 @@ U0 TOSRegen3()
|
||||
TOSProgress("Find /Home");
|
||||
slash_home=F2("/Home","-i+la");
|
||||
|
||||
TOSProgress("ChkDsk All");
|
||||
TOSProgress("DskChk All");
|
||||
Drv('C');
|
||||
ChkAll;
|
||||
DskChkAll;
|
||||
|
||||
TOSProgress("Done");
|
||||
SettingsPop;
|
||||
@@ -570,9 +564,39 @@ public U0 TOSPreRegen()
|
||||
Copy("D:/Home/Sup1/Sup1Blog/Bookmarks.html","C:/Home/Sup1/Sup1Blog");
|
||||
Del("C:/Home/Sup1/Sup1Bin/*");
|
||||
Copy("D:/Home/Sup1/Sup1Bin/*","C:/Home/Sup1/Sup1Bin");
|
||||
Copy("D:/Home/Sup1/Sup1CodeScraps/Comm/TOSSocket*",
|
||||
"C:/Home/Sup1/Sup1CodeScraps/Comm");
|
||||
Copy("D:/Home/Sup1/Sup1Bin/God*","C:/Linux");
|
||||
}
|
||||
|
||||
public U0 TOSHomeIn()
|
||||
{//Copy D:/Home to C:/Home
|
||||
DelTree("C:/Home");
|
||||
CopyTree("D:/Home","C:/Home");
|
||||
}
|
||||
|
||||
public U0 TOSHomeOut()
|
||||
{//Copy C:/Home to D:/Home
|
||||
DelTree("D:/Home");
|
||||
CopyTree("C:/Home","D:/Home");
|
||||
}
|
||||
|
||||
public U0 TOSSongsIn()
|
||||
{//Copy songs from D:/Home/Sup1 to C:/Home/Sup1
|
||||
Del("C:/Home/Sup1/Sup1Hymns/*");
|
||||
Del("C:/Home/Sup1/Sup1Songs/*");
|
||||
Copy("D:/Home/Sup1/Sup1Hymns/*","C:/Home/Sup1/Sup1Hymns");
|
||||
Copy("D:/Home/Sup1/Sup1Songs/*","C:/Home/Sup1/Sup1Songs");
|
||||
}
|
||||
|
||||
public U0 TOSSongsOut()
|
||||
{//Copy songs from C:/Home/Sup1 to D:/Home/Sup1
|
||||
Del("D:/Home/Sup1/Sup1Hymns/*");
|
||||
Del("D:/Home/Sup1/Sup1Songs/*");
|
||||
Copy("C:/Home/Sup1/Sup1Hymns/*","D:/Home/Sup1/Sup1Hymns");
|
||||
Copy("C:/Home/Sup1/Sup1Songs/*","D:/Home/Sup1/Sup1Songs");
|
||||
}
|
||||
|
||||
U0 TOSRegen2()
|
||||
{
|
||||
TOSChgLog; //$LK,"::/Doc/ChgLog.DD"$ datetime matches Kernel $LK,"sys_compile_time",A="MN:sys_compile_time"$.
|
||||
|
||||
@@ -255,7 +255,8 @@ extern U0 FreshenBlog();
|
||||
extern U0 GodBooksPassageU32(U32 rand_u32,U8 *files_find_mask,
|
||||
U8 *file_mask="*",I64 len=512,I64 verbosity=GBP_MEDIUM);
|
||||
extern I64 GodHeaderIns(U8 *type=NULL);
|
||||
extern U0 GodVideo(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename);
|
||||
extern U0 GodVideoDigits(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename);
|
||||
extern U0 GodVideoU32(U32 rand_u32,U8 *filename);
|
||||
extern U0 GodWebIdx(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename)
|
||||
extern U0 GodWordBatch(CHexWordForm *gm);
|
||||
extern U0 TOSBookLines(U8 *book_filename,I64 book_lines,U8 *st,I64 num_lines,
|
||||
|
||||
@@ -178,7 +178,7 @@ U8 *FileDblRead(U8 *filename,I64 line)
|
||||
{//FileDbl's are DolDoc files with 2-line entries.
|
||||
U8 *res=NULL;
|
||||
CDoc *doc=DocRead(filename,DOCF_PLAIN_TEXT_TABS|DOCF_NO_CURSOR);
|
||||
if (DocLineNumGoTo(doc,line-1) && doc->cur_entry->type_u8==DOCT_TEXT)
|
||||
if (DocGoToLine(doc,line-1) && doc->cur_entry->type_u8==DOCT_TEXT)
|
||||
res=StrNew(doc->cur_entry->tag);
|
||||
DocDel(doc);
|
||||
return res;
|
||||
@@ -188,7 +188,7 @@ U8 *FileDblWrite(U8 *filename,I64 line,U8 *st)
|
||||
{//FileDbl's are DolDoc files with 2-line entries.
|
||||
U8 *res=NULL;
|
||||
CDoc *doc=DocRead(filename,DOCF_PLAIN_TEXT_TABS|DOCF_NO_CURSOR);
|
||||
if (DocLineNumGoTo(doc,line-1)) {
|
||||
if (DocGoToLine(doc,line-1)) {
|
||||
if (doc->cur_entry->type_u8==DOCT_TEXT) {
|
||||
Free(doc->cur_entry->tag);
|
||||
doc->cur_entry->tag=StrNew(st);
|
||||
@@ -201,7 +201,7 @@ U8 *FileDblWrite(U8 *filename,I64 line,U8 *st)
|
||||
return res;
|
||||
}
|
||||
|
||||
U0 GodVideo(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename)
|
||||
U0 GodVideoDigits(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename)
|
||||
{
|
||||
U8 *st,*st2;
|
||||
CGodVideoForm *gvf=CAlloc(sizeof(CGodVideoForm));
|
||||
@@ -252,6 +252,36 @@ U0 GodVideo(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename)
|
||||
Free(gvf);
|
||||
}
|
||||
|
||||
U0 GodVideoU32(U32 rand_u32,U8 *filename)
|
||||
{
|
||||
U8 *st,*st2;
|
||||
I64 i,num;
|
||||
Bool old_silent=Silent;
|
||||
num=LineRep(filename,"-S")/2;
|
||||
Silent(old_silent);
|
||||
if (num) {
|
||||
i=rand_u32%num;
|
||||
if (st=FileDblRead(filename,i*2)) {
|
||||
st2=FileDblRead(filename,i*2+1);
|
||||
PutFileLink(filename);
|
||||
"\nGod's response:\n"
|
||||
"%08X-->#%d out of %d\n%s\n",rand_u32,i,num,st;
|
||||
"$$HC,\"<object width=\\\"640\\\" height=\\\"520\\\">"
|
||||
"<param name=\\\"movie\\\" "
|
||||
"value=\\\"http://www.youtube.com/v/%s\\\"></param><param "
|
||||
"name=\\\"allowscriptaccess\\\" "
|
||||
"value=\\\"always\\\"></param><embed "
|
||||
"src=\\\"http://www.youtube.com/v/%s\\\" "
|
||||
"type=\\\"application/x-shockwave-flash\\\" "
|
||||
"allowscriptaccess=\\\"always\\\" "
|
||||
"width=\\\"640\\\" height=\\\"520\\\">"
|
||||
"</embed></object>\"$$\n",st2,st2;
|
||||
Free(st2);
|
||||
Free(st);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
U0 GodWebIdx(U8 *title,U8 *webpage,U8 *rnd,I64 digits,U8 *filename)
|
||||
{
|
||||
U8 *st1,*st2;
|
||||
@@ -414,7 +444,7 @@ U0 TimerGodIns()
|
||||
GodHeaderIns;
|
||||
FifoU8Flush(god.fifo);
|
||||
GodBitsIns(GOD_GOOD_BITS,KbdMsEvtTime>>GOD_BAD_BITS);
|
||||
switch (PopUpPickLst("Hex5Bible\0Hex8Books\0Doodle\0Movie\0Painting100\0"
|
||||
switch (PopUpPickLst("Hex5Bible\0Hex8Books\0Doodle\0Movie100\0Painting100\0"
|
||||
"Painting1000\0Metallica\0")) {
|
||||
case:
|
||||
StrPrint(buf,"%05X",GodBits(5*4));
|
||||
@@ -432,9 +462,9 @@ U0 TimerGodIns()
|
||||
break;
|
||||
case:
|
||||
StrPrint(buf,"%05X",GodBits(2*5*4)); //Little bit risky if no dec.
|
||||
GodVideo("Top 100 Movies",
|
||||
GodVideoDigits("Top 100 Movies",
|
||||
"http://www.afi.com/100years/movies10.aspx",
|
||||
buf,2,"~/Sup1/Sup1Blog/Movies.DD.Z");
|
||||
buf,2,"~/Sup1/Sup1Blog/Movies100.DD.Z");
|
||||
break;
|
||||
case:
|
||||
StrPrint(buf,"%05X",GodBits(2*5*4)); //Little bit risky if no dec.
|
||||
@@ -451,7 +481,7 @@ U0 TimerGodIns()
|
||||
break;
|
||||
case:
|
||||
StrPrint(buf,"%05X",GodBits(2*5*4)); //Little bit risky if no dec.
|
||||
GodVideo("Metallica Song",
|
||||
GodVideoDigits("Metallica Song",
|
||||
"http://home.hccnet.nl/a.r.adams/lyrics/"
|
||||
"metallica/songindex.html",
|
||||
buf,2,"~/Sup1/Sup1Blog/Metallica.DD.Z");
|
||||
@@ -481,8 +511,8 @@ public U0 GodIns()
|
||||
GodHeaderIns;
|
||||
"$$TX,\"%$$Q\",HTML=\"%$$Q\"$$\n",tag,tag;
|
||||
switch (PopUpPickLst("ExtDec5Bible\0LinuxWords\0"
|
||||
"HappyWords\0Hex5Bible\0Hex8Books\0Doodle\0Movie\0Painting100\0"
|
||||
"Painting1000\0Metallica\0")) {
|
||||
"HappyWords\0Hex5Bible\0Hex8Books\0Doodle\0Movie100\0"
|
||||
"Painting100\0Painting1000\0Metallica\0")) {
|
||||
case:
|
||||
if (DocForm(gm(CRandExtDec5Form *)))
|
||||
TOSBookLines("~/Sup1/Sup1Blog/NumBible.TXT",ST_BIBLE_LINES,
|
||||
@@ -524,9 +554,9 @@ public U0 GodIns()
|
||||
break;
|
||||
case:
|
||||
if (DocForm(gm(CMoviesForm *)))
|
||||
GodVideo("Top 100 Movies",
|
||||
GodVideoDigits("Top 100 Movies",
|
||||
"http://www.afi.com/100years/movies10.aspx",
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Movies.DD.Z");
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Movies100.DD.Z");
|
||||
break;
|
||||
case:
|
||||
if (DocForm(gm(CPaintings100Form *))) {
|
||||
@@ -545,7 +575,7 @@ public U0 GodIns()
|
||||
break;
|
||||
case:
|
||||
if (DocForm(gm(CMetallicaForm *)))
|
||||
GodVideo("Metallica Song",
|
||||
GodVideoDigits("Metallica Song",
|
||||
"http://home.hccnet.nl/a.r.adams/lyrics/"
|
||||
"metallica/songindex.html",
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Metallica.DD.Z");
|
||||
@@ -563,13 +593,12 @@ public U0 GodIns()
|
||||
tag="https://passed.pw";
|
||||
break;
|
||||
case GSRC_GENERATE_DATA:
|
||||
tag="http://www.generatedata.com";
|
||||
break;
|
||||
end:
|
||||
GodHeaderIns;
|
||||
"$$TX,\"%$$Q\",HTML=\"%$$Q\"$$\n",tag,tag;
|
||||
switch (PopUpPickLst("ExtDec5Bible\0HexWordBatch\0"
|
||||
"Hex5Bible\0Hex8Books\0Movie\0Metallica\0")) {
|
||||
"Hex5Bible\0Hex8Books\0Movie100\0Metallica\0")) {
|
||||
case:
|
||||
if (DocForm(gm(CRandExtDec5Form *)))
|
||||
TOSBookLines("~/Sup1/Sup1Blog/NumBible.TXT",ST_BIBLE_LINES,
|
||||
@@ -599,13 +628,13 @@ public U0 GodIns()
|
||||
break;
|
||||
case:
|
||||
if (DocForm(gm(CMoviesForm *)))
|
||||
GodVideo("Top 100 Movies",
|
||||
GodVideoDigits("Top 100 Movies",
|
||||
"http://www.afi.com/100years/movies10.aspx",
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Movies.DD.Z");
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Movies100.DD.Z");
|
||||
break;
|
||||
case:
|
||||
if (DocForm(gm(CMetallicaForm *)))
|
||||
GodVideo("Metallica Song",
|
||||
GodVideoDigits("Metallica Song",
|
||||
"http://home.hccnet.nl/a.r.adams/lyrics/"
|
||||
"metallica/songindex.html",
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Metallica.DD.Z");
|
||||
|
||||
@@ -9,7 +9,7 @@ U8 *YouTubeGet(U8 *filename="~/Sup1/Sup1Blog/YouTube.DD.Z",U8 *needle)
|
||||
while (DocFind(doc,line,needle)) {
|
||||
if (!(doc->cur_entry->y&1)) {
|
||||
title=doc->cur_entry->tag;
|
||||
DocLineNumGoTo(doc,doc->cur_entry->y+2);
|
||||
DocGoToLine(doc,doc->cur_entry->y+2);
|
||||
if (doc->cur_entry->type_u8==DOCT_TEXT) {
|
||||
code=doc->cur_entry->tag;
|
||||
DocPrint(doc2,"$$MU-UL,\"%s\",LE=0x%X$$\n",title,code);
|
||||
@@ -177,7 +177,7 @@ U0 TOSIns()
|
||||
public U0 GodCodeJmp()
|
||||
{//Jump to rand code in OS. See $LK,"::/Adam/God/HSNotes.DD"$.
|
||||
CDirEntry *tmpde1=FilesFind("/*",
|
||||
FUF_JUST_FILES|FUF_RECURSE|FUF_JUST_SRC|FUF_CLUSTER_ORDER),
|
||||
FUF_JUST_FILES|FUF_RECURSE|FUF_JUST_SRC|FUF_CLUS_ORDER),
|
||||
*tmpde=tmpde1;
|
||||
I64 cnt=0,num;
|
||||
CDoc *doc;
|
||||
|
||||
@@ -20,7 +20,7 @@ U0 FrameGrabberTask(I64)
|
||||
st_dir="B:/Tmp/ScrnShots";
|
||||
else
|
||||
st_dir="::/Tmp/ScrnShots";
|
||||
MkDir(st_dir);
|
||||
DirMk(st_dir);
|
||||
while (fg_on) {
|
||||
StrPrint(buf,"%s/VID%05d.BMP.Z",st_dir,frame_num++);
|
||||
StrCpy(buf2,buf);
|
||||
@@ -48,7 +48,7 @@ I64 CopyVideo()
|
||||
DelTree("D:/Tmp/ScrnShots");
|
||||
if (fg_mode==FG_RAM_DRV) {
|
||||
res=CopyTree("B:/Tmp/ScrnShots","D:/Tmp/ScrnShots");
|
||||
"Unused Space: %12.6fMeg\n",UnusedDrvSpace('B')/1024.0/1024.0;
|
||||
"Unused Space: %12.6fMeg\n",DrvUnused('B')/1024.0/1024.0;
|
||||
} else
|
||||
res=CopyTree("::/Tmp/ScrnShots","D:/Tmp/ScrnShots");
|
||||
"$$BK,1$$Files Copied:%d$$BK,0$$ Time:%8.3fm\n",
|
||||
@@ -80,7 +80,6 @@ public U0 FrameGrabberToggle()
|
||||
|
||||
public U0 JukeSong(I64 num)
|
||||
{//Make movie of one song.
|
||||
AutoComplete;
|
||||
if (!fg_on)
|
||||
FrameGrabberToggle;
|
||||
JukeSongsPuppet("~/Sup1/Sup1Hymns",,num,num+1);
|
||||
@@ -90,7 +89,6 @@ public U0 JukeSong(I64 num)
|
||||
|
||||
public U0 JukeLines(I64 start_line,I64 end_line)
|
||||
{//Make movie of many lines of songs.
|
||||
AutoComplete;
|
||||
if (!fg_on)
|
||||
FrameGrabberToggle;
|
||||
JukeSongsPuppet("~/Sup1/Sup1Hymns",,start_line*5,end_line*5);
|
||||
@@ -98,11 +96,11 @@ public U0 JukeLines(I64 start_line,I64 end_line)
|
||||
FrameGrabberToggle;
|
||||
}
|
||||
|
||||
public U0 ChkAll()
|
||||
{//ChkDsk on C & D.
|
||||
public U0 DskChkAll()
|
||||
{//DskChk on C & D.
|
||||
U8 *ptr=TOS_HDS;
|
||||
while (*ptr)
|
||||
ChkDsk(*ptr++);
|
||||
DskChk(*ptr++);
|
||||
}
|
||||
|
||||
public CDoc *DC2Doc(CDC *dc,I64 dx=0,I64 dy=0,I64 *_total_score=NULL)
|
||||
@@ -158,11 +156,11 @@ public U0 BMP2Doc(U8 *_in_name,U8 *_out_name=NULL)
|
||||
I64 dx,dy,score,best_score=I64_MAX;
|
||||
CDC *dc;
|
||||
CDoc *doc;
|
||||
in_name=DftExt(_in_name,"BMP");
|
||||
in_name=ExtDft(_in_name,"BMP");
|
||||
if (_out_name)
|
||||
out_name=DftExt(_out_name,"DD.Z");
|
||||
out_name=ExtDft(_out_name,"DD.Z");
|
||||
else
|
||||
out_name=ChgExt(_in_name,"DD.Z");
|
||||
out_name=ExtChg(_in_name,"DD.Z");
|
||||
if (dc=BMPRead(in_name)) {
|
||||
for (dy=-3;dy<=4;dy++)
|
||||
for (dx=-3;dx<=4;dx++) {
|
||||
@@ -187,16 +185,6 @@ U0 TOSTheme()
|
||||
DocClear;
|
||||
}
|
||||
|
||||
U0 TOSJukeVideo(I64 start=0,I64 end=10)
|
||||
{
|
||||
U8 *buf=FileRead("::/Misc/Bible.TXT.Z"); //Put in cache
|
||||
Free(buf);
|
||||
AutoComplete;
|
||||
FrameGrabberToggle;
|
||||
JukeSongsPuppet("~/Sup1/Sup1Hymns",,start,end);
|
||||
FrameGrabberToggle;
|
||||
}
|
||||
|
||||
#define MEM_TEST_SIZE 1024*1024
|
||||
U0 MemTest()
|
||||
{
|
||||
|
||||
@@ -48,7 +48,7 @@ U0 NISTBeaconURL(I64 timestamp)
|
||||
U0 NISTGodIns1()
|
||||
{
|
||||
tos_type=PopUpPickLst("ExtDec5Bible\0LinuxWords\0HappyWords\0"
|
||||
"Hex5Bible\0Hex8Books\0Doodle\0Movie\0Painting100\0Painting1000\0"
|
||||
"Hex5Bible\0Hex8Books\0Doodle\0Movie100\0Painting100\0Painting1000\0"
|
||||
"Metallica\0");
|
||||
switch (tos_type) {
|
||||
case: tos_timestamp=GodHeaderIns("Bible"); break;
|
||||
@@ -56,8 +56,8 @@ U0 NISTGodIns1()
|
||||
case: tos_timestamp=GodHeaderIns("HappyWords"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Bible"); break;
|
||||
case: tos_timestamp=GodHeaderIns("BookPick"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Doodle"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Movie"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Doodle"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Movie100"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Painting100"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Painting1000"); break;
|
||||
case: tos_timestamp=GodHeaderIns("Metallica"); break;
|
||||
@@ -122,9 +122,9 @@ U0 NISTGodIns2()
|
||||
case:
|
||||
if (DocForm(gm(CMoviesForm *))) {
|
||||
NISTBeaconURL(gm->timestamp);
|
||||
GodVideo("Top 100 Movies",
|
||||
GodVideoDigits("Top 100 Movies",
|
||||
"http://www.afi.com/100years/movies10.aspx",
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Movies.DD.Z");
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Movies100.DD.Z");
|
||||
}
|
||||
break;
|
||||
case:
|
||||
@@ -147,7 +147,7 @@ U0 NISTGodIns2()
|
||||
case:
|
||||
if (DocForm(gm(CMetallicaForm *))) {
|
||||
NISTBeaconURL(gm->timestamp);
|
||||
GodVideo("Metallica Song",
|
||||
GodVideoDigits("Metallica Song",
|
||||
"http://home.hccnet.nl/a.r.adams/lyrics/"
|
||||
"metallica/songindex.html",
|
||||
gm->rnd0,2,"~/Sup1/Sup1Blog/Metallica.DD.Z");
|
||||
|
||||
@@ -88,7 +88,7 @@ U8 *TOSLinkCvt2(U8 *filename,I64 line_num)
|
||||
//Make your own LinkCvt routine
|
||||
U8 *res=NULL,*st;
|
||||
if (filename) {
|
||||
st=ChgExt(filename,"html");
|
||||
st=ExtChg(filename,"html");
|
||||
if (st && StrLen(st)>3 && !StrNCmp(st+1,":/",2))
|
||||
res=MStrPrint(PERSONAL_WEB "/%s#l%d",st+3,line_num);
|
||||
Free(st);
|
||||
@@ -189,7 +189,7 @@ public CDoc *Doc2Html(CDoc *doc_in,U8 *html_header=NULL,U8 *body_header=NULL,
|
||||
"<head>\n"
|
||||
"<meta http-equiv=\"Content-Type\" "
|
||||
"content=\"text/html;charset=US-ASCII\">\n"
|
||||
"<meta name=\"generator\" content=\"$TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$\">\n";
|
||||
"<meta name=\"generator\" content=\"$TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$\">\n";
|
||||
if (!body_header) body_header=
|
||||
"<body>\n"
|
||||
"<pre style=\"font-family:courier;font-size:10pt\">\n";
|
||||
@@ -380,11 +380,11 @@ public U0 TOSToHtml(U8 *_in_name,U8 *_out_name=NULL,U8 *html_header=NULL,
|
||||
SettingsPush; //See $LK,"SettingsPush",A="MN:SettingsPush"$
|
||||
WinHorz(0,width-1); //Sets doc width for word wrap.
|
||||
|
||||
in_name=DftExt(_in_name,"HC.Z");
|
||||
in_name=ExtDft(_in_name,"HC.Z");
|
||||
if (_out_name)
|
||||
out_name=DftExt(_out_name,"html");
|
||||
out_name=ExtDft(_out_name,"html");
|
||||
else
|
||||
out_name=ChgExt(_in_name,"html");
|
||||
out_name=ExtChg(_in_name,"html");
|
||||
|
||||
doc_in=DocRead(in_name);
|
||||
DocTop(doc_in);
|
||||
@@ -413,7 +413,7 @@ U0 TOSWebFile(U8 *name,Bool line_nums=FALSE)
|
||||
"File:%s\n",name;
|
||||
Collapse(name,FALSE);
|
||||
Touch(name,"",,de.datetime);
|
||||
name2=ChgExt(name,"html");
|
||||
name2=ExtChg(name,"html");
|
||||
|
||||
if (StrMatch(BLOG_BASE,name) || StrMatch(DAILY_BASE,name))
|
||||
line_anchors=FALSE;
|
||||
@@ -430,7 +430,7 @@ U0 TOSWebFile(U8 *name,Bool line_nums=FALSE)
|
||||
"<meta name=\"keywords\" "
|
||||
"content=\"Operating System,64-Bit,64 Bit,"
|
||||
"Temple,OS,TempleOS,Free,Open Source,Public Domain,x86_64\">\n"
|
||||
"<meta name=\"generator\" content=\"$TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$\">\n",
|
||||
"<meta name=\"generator\" content=\"$TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$\">\n",
|
||||
|
||||
"<body style=\"background-color:#55FFFF; border-style:solid;
|
||||
border-width:8px; border-color:#0000AA;
|
||||
@@ -451,7 +451,7 @@ U0 FreshenWebDir(U8 *dirname,Bool line_nums=FALSE)
|
||||
U8 *src,*dst;
|
||||
|
||||
src=MStrPrint("D:/Wb%s",dirname);
|
||||
MkDir(src);
|
||||
DirMk(src);
|
||||
Free(src);
|
||||
|
||||
src=MStrPrint("D:/Wb%s/*",dirname);
|
||||
@@ -465,7 +465,7 @@ U0 FreshenWebDir(U8 *dirname,Bool line_nums=FALSE)
|
||||
Free(dst);
|
||||
|
||||
src=MStrPrint("D:/Wb%s/*",dirname);
|
||||
tmpde=tmpde1=FilesFind(src,FUF_JUST_FILES|FUF_JUST_TXT|FUF_CLUSTER_ORDER);
|
||||
tmpde=tmpde1=FilesFind(src,FUF_JUST_FILES|FUF_JUST_TXT|FUF_CLUS_ORDER);
|
||||
while (tmpde) {
|
||||
TOSWebFile(tmpde->full_name,line_nums);
|
||||
tmpde=tmpde->next;
|
||||
@@ -487,7 +487,7 @@ public U0 FreshenSite()
|
||||
Touch("D:/Wb/Home/Web/DownloadOS.DD.Z","");
|
||||
Touch("D:/Wb/Home/Web/TempleOS.DD.Z","");
|
||||
tmpde=tmpde1=FilesFind("*",
|
||||
FUF_RECURSE|FUF_JUST_FILES|FUF_JUST_TXT|FUF_CLUSTER_ORDER);
|
||||
FUF_RECURSE|FUF_JUST_FILES|FUF_JUST_TXT|FUF_CLUS_ORDER);
|
||||
while (tmpde) {
|
||||
TOSWebFile(tmpde->full_name);
|
||||
tmpde=tmpde->next;
|
||||
|
||||
@@ -39,7 +39,7 @@ U0 DoIt()
|
||||
|
||||
//$BK,1$WARNING:$BK,0$ If you use the put_doc you
|
||||
//run the risk of the user pressing
|
||||
//<CTRL-t> or using the clipboard, both
|
||||
//<CTRL-t> or using the clip, both
|
||||
//of which will crash. So, you might want
|
||||
//to use the border_doc.
|
||||
|
||||
|
||||
@@ -26,7 +26,7 @@ U0 WriteAcct()
|
||||
MemSet(&a,0,BLK_SIZE);
|
||||
if (DocForm(&a)) {
|
||||
f=FOpen(DB_FILENAME,"w+");
|
||||
FWBlks(f,&a,acctnum*DB_ACCT_BLKS,DB_ACCT_BLKS);
|
||||
FBlkWrite(f,&a,acctnum*DB_ACCT_BLKS,DB_ACCT_BLKS);
|
||||
FClose(f);
|
||||
}
|
||||
}
|
||||
@@ -41,7 +41,7 @@ U0 ReadAcct()
|
||||
acctnum=GetI64("Acct #",-1);
|
||||
if (0<=acctnum<DB_ACCT_MAX) {
|
||||
f=FOpen(DB_FILENAME,"r");
|
||||
FRBlks(f,&a,acctnum*DB_ACCT_BLKS,DB_ACCT_BLKS);
|
||||
FBlkRead(f,&a,acctnum*DB_ACCT_BLKS,DB_ACCT_BLKS);
|
||||
FClose(f);
|
||||
ClassRep(&a);
|
||||
}
|
||||
|
||||
+3
-3
@@ -24,7 +24,7 @@ U0 RawAccess(I64 drv_let=0)
|
||||
|
||||
try {
|
||||
blk=GetI64("Blk to Read: ",old_offset,0,bd->max_blk);
|
||||
RBlks(dv,buf,blk,1);
|
||||
BlkRead(dv,buf,blk,1);
|
||||
D(buf,BLK_SIZE);
|
||||
} catch
|
||||
PutExcept;
|
||||
@@ -37,5 +37,5 @@ U0 RawAccess(I64 drv_let=0)
|
||||
|
||||
RawAccess;
|
||||
|
||||
//See $LK,"RBlks",A="MN:RBlks"$(), $LK,"WBlks",A="MN:WBlks"$(), $LK,"DrvLock",A="MN:DrvLock"$(), $LK,"DrvUnlock",A="MN:DrvUnlock"$()
|
||||
//$LK,"DBlk",A="MN:DBlk"$(), $LK,"DCluster",A="MN:DCluster"$(), $LK,"BlkDevLock",A="MN:BlkDevLock"$() and $LK,"BlkDevUnlock",A="MN:BlkDevUnlock"$().
|
||||
//See $LK,"BlkRead",A="MN:BlkRead"$(), $LK,"BlkWrite",A="MN:BlkWrite"$(), $LK,"DrvLock",A="MN:DrvLock"$(), $LK,"DrvUnlock",A="MN:DrvUnlock"$()
|
||||
//$LK,"DBlk",A="MN:DBlk"$(), $LK,"DClus",A="MN:DClus"$(), $LK,"BlkDevLock",A="MN:BlkDevLock"$() and $LK,"BlkDevUnlock",A="MN:BlkDevUnlock"$().
|
||||
|
||||
@@ -6,7 +6,7 @@ U0 UnusedSpaceRep()
|
||||
if ((dv=Let2Drv(i+'A',FALSE)) &&
|
||||
(dv->fs_type==FSt_FAT32 || dv->fs_type==FSt_REDSEA))
|
||||
"%C: %7.3f%% Free\n",
|
||||
Drv2Let(dv),UnusedDrvSpace(Drv2Let(dv))*100.0/(dv->size*BLK_SIZE);
|
||||
Drv2Let(dv),DrvUnused(Drv2Let(dv))*100.0/(dv->size*BLK_SIZE);
|
||||
}
|
||||
|
||||
UnusedSpaceRep;
|
||||
|
||||
@@ -12,9 +12,9 @@ U0 Rev(U8 *in_name,U8 *out_name)
|
||||
DocTop(doc_in);
|
||||
while (doc_in->head.next!=doc_in) {
|
||||
EdLineDown(doc_in,SC_CURSOR_DOWN|SCF_SHIFT);
|
||||
EdCutToClipboard(doc_in);
|
||||
ClipCut(doc_in);
|
||||
DocTop(doc_out);
|
||||
EdPasteClipboard(doc_out);
|
||||
ClipPaste(doc_out);
|
||||
}
|
||||
DocWrite(doc_out);
|
||||
}
|
||||
|
||||
@@ -16,7 +16,7 @@ $TX,"Source Code By Sym",HTML="http://www.templeos.org/Wb/Home/Web/SymsAlpha.htm
|
||||
|
||||
$LK,"TempleOS Credits",A="FI:::/Doc/Credits.DD"$ $LK,"History of TempleOS",A="FI:~/Web/History.DD"$
|
||||
|
||||
$LK,"Why 640x480?",A="FI:~/Web/640x480.DD"$ $LK,"Dianna Cowern",A="FI:~/Web/DLC/DLC.DD"$
|
||||
$LK,"Why 640x480?",A="FI:~/Web/640x480.DD"$
|
||||
$FG$
|
||||
$LK,"Change Log",A="FI:::/Doc/ChgLog.DD"$ $LK,"Terry Davis",A="FI:~/Web/TAD/TAD.DD"$
|
||||
|
||||
@@ -28,7 +28,7 @@ TempleOS is a free, public domain, open source, $FG,4$$TX,"x86_64",HTML="http://
|
||||
|
||||
The CIA encourages code obsfucation. They make it more complicated than necessary. TempleOS is, literally, more simple than necessary. It is obnoxiously simple... to the point it hurts.
|
||||
|
||||
This $TX,"\"Hello World\" joke",HTML="http://www.infiltec.com/j-h-wrld.htm"$, the $TX,"BMP file format",HTML="http://en.wikipedia.org/wiki/BMP_file_format"$ and the $TX,"WAV file format",HTML="http://en.wikipedia.org/wiki/WAV"$ show that the industry is really screwed-up! That's what TempleOS fixes. I capped the line-of-code count at 100,000 and God said it must be perfect, so it will never be an ugly monstrocity. It is currently $TX,"81,432",D="DD_TEMPLEOS_LOC_OFFICIAL"$ lines of unblemished code. Backward compatibility is not promised.
|
||||
This $TX,"\"Hello World\" joke",HTML="http://www.infiltec.com/j-h-wrld.htm"$, the $TX,"BMP file format",HTML="http://en.wikipedia.org/wiki/BMP_file_format"$ and the $TX,"WAV file format",HTML="http://en.wikipedia.org/wiki/WAV"$ show that the industry is really screwed-up! That's what TempleOS fixes. I capped the line-of-code count at 100,000 and God said it must be perfect, so it will never be an ugly monstrocity. It is currently $TX,"81,933",D="DD_TEMPLEOS_LOC_OFFICIAL"$ lines of unblemished code. Backward compatibility is not promised.
|
||||
|
||||
Normally, failure is not an option, but since TempleOS accompanies Windows or Linux, we exclude certain uses. There is no reason to duplicate browsing, multimedia, desktop publishing, etc. Linux wants to be a secure, multi-user mainframe. That's why it has file permissions. The vision for TempleOS, however, is a modern, 64-bit Commodore 64. The C64 was a non-networked, home computer mostly used for games. It trained my generation how to program because it was wide open, completely hackable. The games were not multimedia works of art, but generated by non-artist.
|
||||
|
||||
@@ -44,7 +44,7 @@ $HC,"<object width=\"640\" height=\"520\"><param name=\"movie\" value=\"http://w
|
||||
|
||||
$HC,"<object width=\"640\" height=\"520\"><param name=\"movie\" value=\"http://www.youtube.com/v/W_b4zMxfLvA\"></param><param name=\"allowscriptaccess\" value=\"always\"></param><embed src=\"http://www.youtube.com/v/W_b4zMxfLvA\" type=\"application/x-shockwave-flash\" allowscriptaccess=\"always\" width=\"640\" height=\"520\"></embed></object>"$
|
||||
|
||||
I wrote all $LK,"121,216",A="FF:~/Web/LineRep.DD,Kernel.PRJ",D="DD_TEMPLEOS_LOC"$ lines of TempleOS over the last $TX,"13.4",D="DD_TEMPLEOS_AGE"$ years, full-time, including the 64-bit compiler. It was called, at various times, "$FG,4$$TX,"Hoppy",HTML="http://web.archive.org/web/*/http://www.simstructure.hare.com/*"$$FG$", "$FG,4$$TX,"The J Operating System",HTML="http://wayback.archive.org/web/*/http://www.justrighteous.org/*"$$FG$", "$FG,4$$TX,"LoseThos",HTML="http://web.archive.org/web/*/http://www.losethos.com/*"$$FG$" and "$FG,4$$TX,"SparrowOS",HTML="http://web.archive.org/web/*/http://www.sparrowos.com/*"$$FG$". Here are my $FG,4$$TX,"college transcripts",HTML="http://www.templeos.org/files/ASU_Transcripts.pdf"$$FG$. I've been a professional operating system developer since 1990 when I was hired to work on Ticketmaster's VAX OS.
|
||||
I wrote all $LK,"119,767",A="FF:~/Web/LineRep.DD,Kernel.PRJ",D="DD_TEMPLEOS_LOC"$ lines of TempleOS over the last $TX,"13.5",D="DD_TEMPLEOS_AGE"$ years, full-time, including the 64-bit compiler. It was called, at various times, "$FG,4$$TX,"Hoppy",HTML="http://web.archive.org/web/*/http://www.simstructure.hare.com/*"$$FG$", "$FG,4$$TX,"The J Operating System",HTML="http://wayback.archive.org/web/*/http://www.justrighteous.org/*"$$FG$", "$FG,4$$TX,"LoseThos",HTML="http://web.archive.org/web/*/http://www.losethos.com/*"$$FG$" and "$FG,4$$TX,"SparrowOS",HTML="http://web.archive.org/web/*/http://www.sparrowos.com/*"$$FG$". Here are my $FG,4$$TX,"college transcripts",HTML="http://www.templeos.org/files/ASU_Transcripts.pdf"$$FG$. I've been a professional operating system developer since 1990 when I was hired to work on Ticketmaster's VAX OS.
|
||||
|
||||
$FG,8$
|
||||
* "Commodore 64" is a trademark owned by Polabe Holding NV.
|
||||
|
||||
@@ -83,7 +83,7 @@ U8 *TOSLinkCvt2(U8 *filename,I64 line_num)
|
||||
//Make your own LinkCvt routine
|
||||
U8 *res=NULL,*st;
|
||||
if (filename) {
|
||||
st=ChgExt(filename,"html");
|
||||
st=ExtChg(filename,"html");
|
||||
if (st && StrLen(st)>3 && !StrNCmp(st+1,":/",2))
|
||||
res=MStrPrint("http://www.templeos.org/Wb/%s#l%d",st+3,line_num);
|
||||
Free(st);
|
||||
@@ -184,7 +184,7 @@ public CDoc *Doc2Html(CDoc *doc_in,U8 *html_header=NULL,U8 *body_header=NULL,
|
||||
"<head>\n"
|
||||
"<meta http-equiv=\"Content-Type\" "
|
||||
"content=\"text/html;charset=US-ASCII\">\n"
|
||||
"<meta name=\"generator\" content=\"$TX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$\">\n";
|
||||
"<meta name=\"generator\" content=\"$TX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$\">\n";
|
||||
if (!body_header) body_header=
|
||||
"<body>\n"
|
||||
"<pre style=\"font-family:courier;font-size:10pt\">\n";
|
||||
@@ -368,11 +368,11 @@ public U0 ToHtml(U8 *_in_name,U8 *_out_name=NULL,U8 *html_header=NULL,
|
||||
SettingsPush; //See $LK,"SettingsPush",A="MN:SettingsPush"$
|
||||
WinHorz(0,width-1); //Sets doc width for word wrap.
|
||||
|
||||
in_name=DftExt(_in_name,"HC.Z");
|
||||
in_name=ExtDft(_in_name,"HC.Z");
|
||||
if (_out_name)
|
||||
out_name=DftExt(_out_name,"html");
|
||||
out_name=ExtDft(_out_name,"html");
|
||||
else
|
||||
out_name=ChgExt(_in_name,"html");
|
||||
out_name=ExtChg(_in_name,"html");
|
||||
|
||||
doc_in=DocRead(in_name);
|
||||
doc_out=Doc2Html(doc_in,html_header,body_header,body_footer,html_footer,
|
||||
|
||||
@@ -59,7 +59,7 @@ U0 LogScrambleDemo()
|
||||
{
|
||||
U8 *dirname;
|
||||
Cd(__DIR__);
|
||||
dirname=CurDir;
|
||||
dirname=DirCur;
|
||||
ST_WARN_ST "This will scramble all .LOG files in '%s'.\n\n",dirname;
|
||||
Free(dirname);
|
||||
if (AreYouSure)
|
||||
|
||||
+30
-3
@@ -2,7 +2,34 @@ $WW,1$$FG,5$$TX+CX,"Change Log"$$FG$
|
||||
|
||||
Use $LK,"R",A="MN:R"$() to rename if I change a label.
|
||||
|
||||
$IV,1$----01/19/17 07:21:14----$IV,0$
|
||||
$IV,1$----01/25/17 20:44:17----$IV,0$
|
||||
* $LK,"R",A="MN:R"$("DocLineNumGoto","DocGoToLine");
|
||||
* $LK,"R",A="MN:R"$("Clipboard","Clip");
|
||||
* $LK,"R",A="MN:R"$("AutoMountIDE","MountIDEAuto");
|
||||
* $LK,"R",A="MN:R"$("ChgExt","ExtChg");
|
||||
* $LK,"R",A="MN:R"$("DftExt","ExtDft");
|
||||
* $LK,"R",A="MN:R"$("CurDir","DirCur");
|
||||
* $LK,"R",A="MN:R"$("MkDir","DirMk");
|
||||
* $LK,"R",A="MN:R"$("ChkDsk","DskChk");
|
||||
* $LK,"R",A="MN:R"$("ChgDsk","DskChg");
|
||||
* $LK,"R",A="MN:R"$("PrtDsk","DskPrt");
|
||||
* $LK,"R",A="MN:R"$("RBlks","BlkRead");
|
||||
* $LK,"R",A="MN:R"$("WBlks","BlkWrite");
|
||||
* $LK,"R",A="MN:R"$("FRBlks","FBlkRead");
|
||||
* $LK,"R",A="MN:R"$("FWBlks","FBlkWrite");
|
||||
* $LK,"R",A="MN:R"$("Cluster","Clus");
|
||||
* $LK,"R",A="MN:R"$("RClusters","ClusRead");
|
||||
* $LK,"R",A="MN:R"$("WClusters","ClusWrite");
|
||||
|
||||
|
||||
$IV,1$----01/24/17 21:56:06----$IV,0$
|
||||
* Improved $LK,"::/Apps/Psalmody/JukeBox.HC"$
|
||||
* $LK,"R",A="MN:R"$("TreeBranch","Tree");
|
||||
* Added $LK,"DocTreeWrite",A="MN:DocTreeWrite"$() and $LK,"DocTreeAppend",A="MN:DocTreeAppend"$().
|
||||
|
||||
$IV,1$----01/22/17 06:08:00----$IV,0$
|
||||
* $BK,1$TempleOS version 5.02 Released$BK,0$
|
||||
* Changed polling of $LK,"KbdMsHndlr",A="MN:KbdMsHndlr"$() in $LK,"WinMgrSleep",A="MN:WinMgrSleep"$(), increased fifos.
|
||||
|
||||
$IV,1$----01/17/17 18:11:53----$IV,0$
|
||||
* Fixed $FG,2$$$$FG$ class offset so $FG,2$#assert$FG$'s don't lag a token.
|
||||
@@ -46,7 +73,7 @@ $IV,1$----01/10/17 11:45:41----$IV,0$
|
||||
* Added $LK,"::/Adam/InsReg.HC"$ with $LK,"InsReg",A="MN:InsReg"$(), $LK,"InsRereg",A="MN:InsRereg"$() and $LK,"InsUnreg",A="MN:InsUnreg"$().
|
||||
* Added $LK,"::/Adam/Host.HC"$ with $LK,"HostChgDsk",A="MN:HostChgDsk"$().
|
||||
* Added $LK,"::/Adam/Opt/Utils/TOS.HC"$ with $LK,"TOSStdIns",A="MN:TOSStdIns"$().
|
||||
* Added cmd line args for partition % to $LK,"PrtDsk",A="MN:PrtDsk"$().
|
||||
* Added cmd line args for partition % to $LK,"DskPrt",A="MN:DskPrt"$().
|
||||
|
||||
$IV,1$----01/09/17 21:48:34----$IV,0$
|
||||
* $LK,"R",A="MN:R"$("a1","arg1");
|
||||
@@ -62,7 +89,7 @@ $IV,1$----01/09/17 02:30:59----$IV,0$
|
||||
* Moved AfterEgypt to the supplemental disk.
|
||||
|
||||
$IV,1$----01/06/17 06:07:19----$IV,0$
|
||||
* Fixed $LK,"ChgDsk",A="MN:ChgDsk"$().
|
||||
* Fixed $LK,"DskChg",A="MN:DskChg"$().
|
||||
* Improved $LK,"::/Misc/OSTestSuite.HC"$.
|
||||
|
||||
$IV,1$----01/05/17 04:53:21----$IV,0$
|
||||
|
||||
+84
-68
@@ -5,11 +5,6 @@ it in your start-up scripts.
|
||||
|
||||
#help_index "Comm"
|
||||
|
||||
#define COM1_BASE 0x3F8
|
||||
#define COM2_BASE 0x2F8
|
||||
#define COM3_BASE 0x3E8
|
||||
#define COM4_BASE 0x2E8
|
||||
|
||||
#define UART_THR 0
|
||||
#define UART_RDR 0
|
||||
#define UART_BRDL 0
|
||||
@@ -21,96 +16,117 @@ it in your start-up scripts.
|
||||
#define UART_LSR 5
|
||||
#define UART_MSR 6
|
||||
|
||||
I64 comm_base[5]={0,0x3F8,0x2F8,0x3E8,0x2E8};
|
||||
#define COMf_ENABLED 0
|
||||
class CComm
|
||||
{
|
||||
I64 base,
|
||||
flags;
|
||||
CFifoU8 *RX_fifo;
|
||||
CFifoU8 *TX_fifo;
|
||||
} comm_ports[5];
|
||||
|
||||
CFifoU8 *comm_fifos[5]={NULL,NULL,NULL,NULL,NULL};
|
||||
U0 CommHndlr(I64 port)
|
||||
{
|
||||
CComm *c=&comm_ports[port];
|
||||
I64 b=0,stat;
|
||||
if (Bt(&c->flags,COMf_ENABLED)) {
|
||||
stat=InU8(c->base+UART_IIR);
|
||||
if (stat & 4) //RX
|
||||
FifoU8Ins(c->RX_fifo,InU8(c->base+UART_RDR));
|
||||
if (stat & 2) { //TX
|
||||
if (FifoU8Rem(c->TX_fifo,&b))
|
||||
OutU8(c->base+UART_THR,b);
|
||||
else
|
||||
OutU8(c->base+UART_IER,1); //RX but no THR empty
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
interrupt U0 IRQComm3()
|
||||
{
|
||||
I64 base=comm_base[2];
|
||||
if (comm_fifos[2] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
||||
FifoU8Ins(comm_fifos[2],InU8(base+UART_RDR));
|
||||
|
||||
base=comm_base[4];
|
||||
if (comm_fifos[4] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
||||
FifoU8Ins(comm_fifos[4],InU8(base+UART_RDR));
|
||||
CommHndlr(2);
|
||||
CommHndlr(4);
|
||||
OutU8(0x20,0x20);
|
||||
}
|
||||
|
||||
interrupt U0 IRQComm4()
|
||||
{
|
||||
I64 base=comm_base[1];
|
||||
if (comm_fifos[1] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
||||
FifoU8Ins(comm_fifos[1],InU8(base+UART_RDR));
|
||||
|
||||
base=comm_base[3];
|
||||
if (comm_fifos[3] && (InU8(base+UART_IIR) & 0xFE)==4) //RX IRQ
|
||||
FifoU8Ins(comm_fifos[3],InU8(base+UART_RDR));
|
||||
CommHndlr(1);
|
||||
CommHndlr(3);
|
||||
OutU8(0x20,0x20);
|
||||
}
|
||||
|
||||
IntEntrySet(0x23,&IRQComm3);
|
||||
IntEntrySet(0x24,&IRQComm4);
|
||||
|
||||
public U0 CommInit8n1(I64 port,I64 baud)
|
||||
U0 CommInit()
|
||||
{
|
||||
I64 base=comm_base[port];
|
||||
MemSet(&comm_ports,0,sizeof(comm_ports));
|
||||
comm_ports[1].base=0x3F8;
|
||||
comm_ports[2].base=0x2F8;
|
||||
comm_ports[3].base=0x3E8;
|
||||
comm_ports[4].base=0x2E8;
|
||||
IntEntrySet(0x23,&IRQComm3);
|
||||
IntEntrySet(0x24,&IRQComm4);
|
||||
}
|
||||
CommInit;
|
||||
|
||||
public CComm *CommInit8n1(I64 port,I64 baud)
|
||||
{
|
||||
CComm *c=&comm_ports[port];
|
||||
|
||||
PUSHFD
|
||||
CLI
|
||||
if (comm_fifos[port])
|
||||
FifoU8Del(comm_fifos[port]);
|
||||
comm_fifos[port]=FifoU8New(256);
|
||||
OutU8(base+UART_LCR,0); //Set for IER
|
||||
OutU8(base+UART_IER,0); //Disable all IRQ
|
||||
OutU8(base+UART_LCR,0x80); //Enable baud rate control
|
||||
OutU8(base+UART_BRDL,(0x180/(baud/300)) & 0xFF); //LSB
|
||||
OutU8(base+UART_BRDH,(0x180/(baud/300)) / 256); //MSB
|
||||
OutU8(base+UART_LCR,3); // 8-none-1
|
||||
if (LBts(&c->flags,COMf_ENABLED)) {
|
||||
FifoU8Del(c->RX_fifo);
|
||||
FifoU8Del(c->TX_fifo);
|
||||
}
|
||||
c->RX_fifo=FifoU8New(256);
|
||||
c->TX_fifo=FifoU8New(256);
|
||||
OutU8(c->base+UART_LCR,0); //Set for IER
|
||||
OutU8(c->base+UART_IER,0); //Disable all IRQ
|
||||
OutU8(c->base+UART_LCR,0x80); //Enable baud rate control
|
||||
OutU8(c->base+UART_BRDL,(0x180/(baud/300)) & 0xFF); //LSB
|
||||
OutU8(c->base+UART_BRDH,(0x180/(baud/300)) / 256); //MSB
|
||||
OutU8(c->base+UART_LCR,3); //8-none-1
|
||||
|
||||
InU8(base+UART_RDR); //read garbage
|
||||
InU8(base+UART_LSR);
|
||||
InU8(c->base+UART_RDR); //read garbage
|
||||
InU8(c->base+UART_LSR);
|
||||
|
||||
OutU8(base+UART_MCR,4);
|
||||
OutU8(base+UART_IER,0); //Disable all IRQ
|
||||
OutU8(base+UART_MCR,0xA); //out2 and rts
|
||||
OutU8(0x21,InU8(0x21) & (0xFF-0x18)); //Enable 8259 IRQ 3 & 4
|
||||
OutU8(base+UART_IER,1); //Enable RX IRQ
|
||||
OutU8(c->base+UART_MCR,4);
|
||||
OutU8(c->base+UART_IER,0); //Disable all IRQ
|
||||
OutU8(c->base+UART_MCR,0xA); //out2 and rts
|
||||
OutU8(0x21,InU8(0x21) & (0xFF-0x18)); //Enable 8259 IRQ 3 & 4
|
||||
OutU8(c->base+UART_IER,1); //RX but no THR empty
|
||||
POPFD
|
||||
|
||||
return c;
|
||||
}
|
||||
|
||||
public U0 CommBusyPutChar(I64 port,U8 b)
|
||||
public U0 CommPutChar(I64 port,U8 b)
|
||||
{
|
||||
I64 base=comm_base[port];
|
||||
while (!(InU8(base+UART_LSR) & 0x20))
|
||||
Yield;
|
||||
OutU8(base+UART_THR,b);
|
||||
while (!(InU8(base+UART_LSR) & 0x20))
|
||||
Yield;
|
||||
CComm *c=&comm_ports[port];
|
||||
PUSHFD
|
||||
CLI
|
||||
FifoU8Ins(c->TX_fifo,b);
|
||||
OutU8(c->base+UART_IER,3); //RX and THR empty
|
||||
POPFD
|
||||
Sleep(10); //!!! Remove this line!!! Linux echo_socket is too slow.
|
||||
}
|
||||
|
||||
public U0 CommBusyPutS(I64 port,U8 *st)
|
||||
U0 CommPutS(I64 port,U8 *st)
|
||||
{
|
||||
I64 b,base=comm_base[port];
|
||||
while (b=*(st++)) {
|
||||
while (!(InU8(base+UART_LSR) & 0x20))
|
||||
Yield;
|
||||
OutU8(base+UART_THR,b);
|
||||
}
|
||||
while (!(InU8(base+UART_LSR) & 0x20))
|
||||
Yield;
|
||||
I64 b;
|
||||
while (b=*st++)
|
||||
CommPutChar(port,b);
|
||||
}
|
||||
|
||||
public U0 CommBusyWriteBlk(I64 port,U8 *buf,I64 count)
|
||||
public U0 CommPutBlk(I64 port,U8 *buf,I64 cnt)
|
||||
{
|
||||
I64 base=comm_base[port];
|
||||
while (count--) {
|
||||
while (!(InU8(base+UART_LSR) & 0x20))
|
||||
Yield;
|
||||
OutU8(base+UART_THR,*(buf++));
|
||||
}
|
||||
while (!(InU8(base+UART_LSR) & 0x20))
|
||||
Yield;
|
||||
while (cnt--)
|
||||
CommPutChar(port,*buf++);
|
||||
}
|
||||
|
||||
#help_index ""
|
||||
public U0 CommPrint(I64 port,U8 *fmt,...)
|
||||
{
|
||||
U8 *buf=StrPrintJoin(NULL,fmt,argc,argv);
|
||||
CommPutS(port,buf);
|
||||
Free(buf);
|
||||
}
|
||||
|
||||
+1
-1
@@ -11,7 +11,7 @@ See $LK,"::/Kernel/BlkDev/FileSysRedSea.HC"$ and $LK,"::/Adam/Opt/Boot/DskISORed
|
||||
$LK,"::/Kernel/BlkDev/FileSysFAT.HC"$ :974 lines for FAT32 gets eliminated.
|
||||
$LK,"::/Kernel/BlkDev/FileSysISO.HC"$ :233 lines for ISO9660 gets eliminated.
|
||||
$LK,"::/Adam/Opt/Boot/DskISO9660.HC"$ :507 lines for making ISO files.
|
||||
$LK,"::/Kernel/BlkDev/DskCluster.HC"$ :152 All the cluster operations become blk.
|
||||
$LK,"::/Kernel/BlkDev/DskClus.HC"$ :152 All the clus operations become blk.
|
||||
|
||||
* Microsoft must cancel SecureBoot because it makes dual booting impossible. TempleOS is an additional operating system that must be used along-side Windows or Linux, not as a replacement. It must dual boot because it has no networking. Real hardware as opposed to VMware is like the difference between looking in a telescope eye piece vs just looking at an off-line image. God said the C64/Apple II generation owned ancestral lands. VMware is like being taken off of our land and moved onto a reservation. In this case, however, it will not stand.
|
||||
|
||||
|
||||
@@ -165,7 +165,7 @@ You might want to use $LK,"DocPrintAtomic",A="MN:DocPrintAtomic"$().
|
||||
|
||||
See $LK,"::/Demo/DolDoc/TreeDemo.HC"$.
|
||||
$ID,-2$$TR,"SP Sprite"$
|
||||
$ID,2$Insert a sprite into text with $FG,2$<CTRL-r>$FG$. The cursor location at the time you press $FG,2$<CTRL-r>$FG$ is critical because the sprite will be offset from that location. This is important when adding images to programs. Numbers for sprites are automatically chosen because copying to and from the clipboard requires this. You can insert another sprite with the same image by hitting $FG,2$<CTRL-t>$FG$ and manually adding a $FG,2$$$SP...$$$FG$ entry with the same $FG,2$BI=$FG$ num.
|
||||
$ID,2$Insert a sprite into text with $FG,2$<CTRL-r>$FG$. The cursor location at the time you press $FG,2$<CTRL-r>$FG$ is critical because the sprite will be offset from that location. This is important when adding images to programs. Numbers for sprites are automatically chosen because copying to and from the clip requires this. You can insert another sprite with the same image by hitting $FG,2$<CTRL-t>$FG$ and manually adding a $FG,2$$$SP...$$$FG$ entry with the same $FG,2$BI=$FG$ num.
|
||||
|
||||
You can add a text tag to the $FG,2$$$SP...$$$FG$ cmd by manually adding text into the $FG,2$$$SP...$$$FG$ cmd, as in $FG,2$$$SP,"pic 2",BI=2$$$FG$. If you enter a tag of the form $FG,2$"<1>"$FG$ then the number in the tag will be updated to match the $FG,2$BI=$FG$ number.
|
||||
$ID,-2$$TR,"IB Insert Binary"$
|
||||
|
||||
+1
-1
@@ -20,7 +20,7 @@
|
||||
|
||||
* ATAPI PIO $FG,2$CD/DVD$FG$ support with $FG,2$ISO9660$FG$ file system. Can make bootable $FG,2$ISO9660$FG$ ISO files so you can roll-your-own distro's.
|
||||
|
||||
* $LK,"Partitioning",A="MN:PrtDsk"$ tool, installer, $FG,2$boot loaders$FG$ for CD/DVD and hard disk.
|
||||
* $LK,"Partitioning",A="MN:DskPrt"$ tool, installer, $FG,2$boot loaders$FG$ for CD/DVD and hard disk.
|
||||
|
||||
* $FG,2$Editor/Browser$FG$ for a new $LK,"Document Format",A="FI:::/Doc/DolDocOverview.DD"$. Source files and the command line window can have graphics, links, icons, trees, colors, super/sub scripts, margins. Everything is seamless through-out the tool chain. No need for separate resource files.
|
||||
|
||||
|
||||
Binary file not shown.
+5
-5
@@ -3,14 +3,14 @@ $WW,1$$FG,5$$TX+CX,"File Manager"$$FG$
|
||||
$FG,2$<SHIFT CURSOR>$FG$
|
||||
$ID,2$Select files.
|
||||
$ID,-2$
|
||||
$FG,2$<CTRL-y> or <DELETE>$FG$
|
||||
$FG,2$<CTRL-y> or <DEL>$FG$
|
||||
$ID,2$Delete file or tree.
|
||||
$ID,-2$
|
||||
$FG,2$<CTRL-c> or <CTRL-INS>$FG$
|
||||
$ID,2$Copy select files to clipboard.
|
||||
$ID,2$Copy select files to clip.
|
||||
$ID,-2$
|
||||
$FG,2$<CTRL-v> or <SHIFT-INS>$FG$
|
||||
$ID,2$Paste clipboard.
|
||||
$ID,2$Paste clip.
|
||||
$ID,-2$
|
||||
$FG,2$LEFT-CLICK,drag-drop$FG$
|
||||
$ID,2$Move a file or tree to a dir.
|
||||
@@ -37,7 +37,7 @@ $FG,2$'d'$FG$
|
||||
$ID,2$Make Dir.
|
||||
$ID,-2$
|
||||
$FG,2$'c'$FG$
|
||||
$ID,2$ChgDsk (Remount removable media). Do not do this on blank disks.
|
||||
$ID,2$DskChg (Remount removable media). Do not do this on blank disks.
|
||||
$ID,-2$
|
||||
$FG,2$'f'$FG$
|
||||
$ID,2$Format drive.
|
||||
@@ -59,7 +59,7 @@ $ID,2$Burn CD/DVD ISO file. This burns a CD/DVD using the image file, $FG,2$$TX
|
||||
$ID,-2$
|
||||
|
||||
$FG,5$Instructions on Using CD/DVD's$FG$
|
||||
$ID,2$If you have not recompiled Kernel and defined your CD/DVD drive, exit the FileMgr and use $LK,"Mount",A="MN:Mount"$ to define your CD/DVD drive. Place a CD/DVD in the drive and press $FG,2$'c'$FG$ when on top of the CD/DVD drive letter to mount the drive. It will call $LK,"ChgDsk",A="MN:ChgDsk"$(), the TempleOS cmd to mount removable media.
|
||||
$ID,2$If you have not recompiled Kernel and defined your CD/DVD drive, exit the FileMgr and use $LK,"Mount",A="MN:Mount"$ to define your CD/DVD drive. Place a CD/DVD in the drive and press $FG,2$'c'$FG$ when on top of the CD/DVD drive letter to mount the drive. It will call $LK,"DskChg",A="MN:DskChg"$(), the TempleOS cmd to mount removable media.
|
||||
$ID,-2$
|
||||
|
||||
$FG,5$Instructions on Burning CD/DVD's$FG$
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
File
|
||||
{
|
||||
Rename(,'r');
|
||||
MkDir(,'d');
|
||||
DirMk(,'d');
|
||||
FmtDrv(,'f');
|
||||
UnmountDrv(,'u');
|
||||
Abort(,CH_SHIFT_ESC);
|
||||
@@ -19,7 +19,7 @@ Edit
|
||||
|
||||
CDDVD
|
||||
{
|
||||
ChgDsk(,'c');
|
||||
DskChg(,'c');
|
||||
MountISOC(,'i');
|
||||
MakeRedSeaISOC(,'m');
|
||||
MakeISO9660ISO(,'M');
|
||||
|
||||
+1
-1
@@ -16,7 +16,7 @@ Flags are either text or int values.
|
||||
$LK,"FUF_FLATTEN_TREE",A="MN:FUF_FLATTEN_TREE"$ $FG,2$+f$FG$ use with '$FG,2$+F$FG$'. Just use $FG,2$+F$FG$, probably.
|
||||
$LK,"FUF_JUST_DIRS",A="MN:FUF_JUST_DIRS"$ $FG,2$+D$FG$ just directories
|
||||
$LK,"FUF_JUST_FILES",A="MN:FUF_JUST_FILES"$ $FG,2$+F$FG$ just files (Flattens trees)
|
||||
$LK,"FUF_CLUSTER_ORDER",A="MN:FUF_CLUSTER_ORDER"$ $FG,2$+O$FG$ sort by cluster (move head one direction)
|
||||
$LK,"FUF_CLUS_ORDER",A="MN:FUF_CLUS_ORDER"$ $FG,2$+O$FG$ sort by clus (move head one direction)
|
||||
$LK,"FUF_JUST_TXT",A="MN:FUF_JUST_TXT"$ $FG,2$+T$FG$ just text files : $LK,"FILEMASK_TXT",A="MN:FILEMASK_TXT"$
|
||||
$LK,"FUF_JUST_DD",A="MN:FUF_JUST_DD"$ $FG,2$+$$$FG$ just $LK,"DolDoc",A="FI:::/Doc/DolDocOverview.DD"$ files : $LK,"FILEMASK_DD",A="MN:FILEMASK_DD"$
|
||||
$LK,"FUF_JUST_SRC",A="MN:FUF_JUST_SRC"$ $FG,2$+S$FG$ just src files : $LK,"FILEMASK_SRC",A="MN:FILEMASK_SRC"$
|
||||
|
||||
+4
-2
@@ -25,11 +25,13 @@ $FG,2$CB$FG$ Call-Back, Code Block
|
||||
$FG,2$Cfg$FG$ Config
|
||||
$FG,2$Chg$FG$ Change
|
||||
$FG,2$Chk$FG$ Check
|
||||
$FG,2$Const$FG$ Consant
|
||||
$FG,2$Cont$FG$ Continue
|
||||
$FG,2$Clip$FG$ Clipboard
|
||||
$FG,2$Clus$FG$ Cluster
|
||||
$FG,2$Cmd$FG$ Command
|
||||
$FG,2$Cmp$FG$ Compiler
|
||||
$FG,2$Cnt$FG$ Count
|
||||
$FG,2$Const$FG$ Consant
|
||||
$FG,2$Cont$FG$ Continue
|
||||
$FG,2$Ctrl$FG$ Control. The ctrl key is indicated with "$FG,2$^$FG$" in documentation.
|
||||
$FG,2$Cur$FG$ Current
|
||||
$FG,2$Cvt$FG$ Convert
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@ Two TempleOS partitions are highly recommended, so you can boot to a back-up and
|
||||
$ID,2$$LK,"Mount",A="MN:Mount"$() use if the drive is partitioned.
|
||||
$ID,2$This command mounts a drive making it accessible. For simplicity, sel $FG,2$'C'$FG$ as the first drive letter for your hard drive. The first partition will be $FG,2$'C'$FG$, second, $FG,2$'D'$FG$, etc. TempleOS needs 3 numbers to utilize a hard drive -- base0, base1, and unit. When you enter a hexadecimal number, do it like in $FG,2$C$FG$ with a $FG,2$0x$FG$ prefix. If the probe was successful, you can just enter the number in the probe box instead of base0.
|
||||
$ID,-2$
|
||||
$LK,"PrtDsk",A="MN:PrtDsk"$($FG,2$'C'$FG$) use if drive is not partitioned
|
||||
$LK,"DskPrt",A="MN:DskPrt"$($FG,2$'C'$FG$) use if drive is not partitioned
|
||||
|
||||
$ID,2$This will perform a special $LK,"Mount",A="MN:Mount"$() automatically.
|
||||
|
||||
|
||||
+2
-2
@@ -8,9 +8,9 @@ $WW,1$* You run a risk of problems if you do file operations on the same files s
|
||||
|
||||
* The syntax highlighting occassionally glitches. The compiler doesn't.
|
||||
|
||||
* Call $LK,"ChgDsk",A="MN:ChgDsk"$() when you insert a new removable media.
|
||||
* Call $LK,"DskChg",A="MN:DskChg"$() when you insert a new removable media.
|
||||
|
||||
* Accessing CD/DVD's is flacky. Try $LK,"Drv",A="MN:Drv"$() or $LK,"ChgDsk",A="MN:ChgDsk"$() twice.
|
||||
* Accessing CD/DVD's is flacky. Try $LK,"Drv",A="MN:Drv"$() or $LK,"DskChg",A="MN:DskChg"$() twice.
|
||||
|
||||
* You can only $FG,2$extern$FG$ something once. There is a varient called $FG,2$_extern$FG$ which binds a HolyC definition to a asm sym. This, too, can only be done once.
|
||||
|
||||
|
||||
+3
-3
@@ -1,6 +1,6 @@
|
||||
$WW,1$$FG,5$$TX+CX,"RedSea File System"$$FG$
|
||||
|
||||
The RedSea file system is a simple, 64-bit, file system which is similar to FAT32, but with absolute block addresses instead of clusters, fixed-sized 64-byte directory entries and no FAT table, just an allocation bitmap. A cluster is just one 512 byte sector. Files are stored in contiguous blocks and cannot grow in size.
|
||||
The RedSea file system is a simple, 64-bit, file system which is similar to FAT32, but with absolute block addresses instead of clus, fixed-sized 64-byte directory entries and no FAT table, just an allocation bitmap. A clus is just one 512 byte sector. Files are stored in contiguous blocks and cannot grow in size.
|
||||
|
||||
$HL,1$#define CDIR_FILENAME_LEN 38 //Must include terminator zero
|
||||
|
||||
@@ -13,7 +13,7 @@ public class CDirEntry //64-byte fixed-size
|
||||
{
|
||||
U16 attr; //See $LK,"RS_ATTR_DIR",A="MN:RS_ATTR_DIR"$. I would like to change these.
|
||||
U8 name[CDIR_FILENAME_LEN]; //See $LK,"char_bmp_filename",A="MN:char_bmp_filename"$, $LK,"FileNameChk",A="MN:FileNameChk"$
|
||||
I64 cluster; (blk) //One sector per cluster.
|
||||
I64 clus; (blk) //One sector per clus.
|
||||
I64 size; //In bytes
|
||||
CDate datetime; //See $LK,"DateTime",A="::/Doc/TimeDate.DD"$, $LK,"Implementation of DateTime",A="FI:::/Kernel/KDate.HC"$
|
||||
};
|
||||
@@ -24,7 +24,7 @@ public class CRedSeaBoot //RedSea is type FAT32 in partition table to fool BIOS.
|
||||
U8 signature,reserved[4]; //MBR_PT_REDSEA=0x88. Distinguish from real FAT32.
|
||||
I64 drv_offset; //For CD/DVD image copy.
|
||||
I64 sects;
|
||||
I64 root_cluster; (root_blk)
|
||||
I64 root_clus; (root_blk)
|
||||
I64 bitmap_sects;
|
||||
I64 unique_id;
|
||||
U8 code[462];
|
||||
|
||||
+1
-1
@@ -2,6 +2,6 @@ $WW,1$A $LK,"CSprite",A="MN:CSprite"$ is an ordered list of $LK,"these",A="MN:SP
|
||||
|
||||
See $LK,"::/Demo/Graphics/SpritePlot.HC"$, $LK,"::/Demo/Graphics/SpritePlot3D.HC"$, $LK,"::/Demo/Graphics/SpritePut.HC"$, $LK,"::/Demo/Graphics/SpriteRaw.HC"$ and $LK,"SpriteMeshEd",A="MN:SpriteMeshEd"$().
|
||||
|
||||
Be aware that copying $FG,2$SP$FG$, $FG,2$IB$FG$, or $FG,2$IS$FG$ entries with the clipboard results in duplicate entries with different nums. You can manually remove dups by editing with $FG,2$<CTRL-t>$FG$ and setting to the original num.
|
||||
Be aware that copying $FG,2$SP$FG$, $FG,2$IB$FG$, or $FG,2$IS$FG$ entries with the clip results in duplicate entries with different nums. You can manually remove dups by editing with $FG,2$<CTRL-t>$FG$ and setting to the original num.
|
||||
|
||||
See $LK,"::/Adam/Gr/GrSpritePlot.HC",A="FL:::/Adam/Gr/GrSpritePlot.HC,1"$ for how CSprite are stored.$FG$
|
||||
|
||||
+1
-1
@@ -1,5 +1,5 @@
|
||||
$WW,1$$FG,5$$TX+CX,"Sprite BitMap Menu Help"$$FG$
|
||||
|
||||
BitMaps have a background color. If you delete to the clipboard, what's left will be background colored.
|
||||
BitMaps have a background color. If you delete to the clip, what's left will be background colored.
|
||||
|
||||
While drawing, you can usually press $FG,2$'c'$FG$ to eye-dropper the color under the mouse. Press $FG,2$'t'$FG$ for transparent.
|
||||
|
||||
+1
-1
@@ -4,4 +4,4 @@ Order of elements matters. They are executed in the order they appear in the si
|
||||
|
||||
You can set the current insert point element by clicking the element in the side-bar and making it RED.
|
||||
|
||||
$FG,2$Insert Shift Suborigin$FG$ is an element which shifts subsequent elements. Perhaps, you inserted a sprite's elements from the clipboard and want to shift it around? This command is also useful if you call $LK,"SpriteInterpolate",A="MN:SpriteInterpolate"$() in programs.
|
||||
$FG,2$Insert Shift Suborigin$FG$ is an element which shifts subsequent elements. Perhaps, you inserted a sprite's elements from the clip and want to shift it around? This command is also useful if you call $LK,"SpriteInterpolate",A="MN:SpriteInterpolate"$() in programs.
|
||||
|
||||
+1
-1
@@ -1,4 +1,4 @@
|
||||
$WW+H,1$$FG,5$$TX+CX,"TempleOS V5.01",D="DD_OS_NAME_VERSION"$$FG$
|
||||
$WW+H,1$$FG,5$$TX+CX,"TempleOS V5.02",D="DD_OS_NAME_VERSION"$$FG$
|
||||
|
||||
$TX+CX,"Public Domain Operating System"$
|
||||
|
||||
|
||||
+2
-2
@@ -71,7 +71,7 @@ $FG,2$Merge(\"C:/*\",\"D:/*\",\"+r+d\");$FG$ to check my changes.
|
||||
|
||||
* Use $FG,2$<CTRL-ALT-f>$FG$ to toggle between $LK,"Std Font",A="FI:::/Kernel/FontStd.HC"$ and $LK,"Cyrillic Font",A="FI:::/Kernel/FontCyrillic.HC"$.
|
||||
|
||||
* Use $FG,2$<CTRL-ALT-s>$FG$ will capture the scrn as a sprite on the clipboard. You can save the cmd line doc as text with $FG,2$<CTRL-a>$FG$.
|
||||
* Use $FG,2$<CTRL-ALT-s>$FG$ will capture the scrn as a sprite on the clip. You can save the cmd line doc as text with $FG,2$<CTRL-a>$FG$.
|
||||
|
||||
* You can save a sprite as a $FG,2$.BMP$FG$ file in $FG,2$<CTRL-r>$FG$ on the Sprite BitMap Menu.
|
||||
|
||||
@@ -145,7 +145,7 @@ $FG,2$Merge(\"C:/*\",\"D:/*\",\"+r+d\");$FG$ to check my changes.
|
||||
|
||||
* With $FG,2$start$FG$/$FG,2$end$FG$, common trailing code is fast. Common leading code is slow.$FG$
|
||||
|
||||
* The first line of the $MA-X+PU,"Psalmody",LM="#include \"::/Apps/Psalmody/Run\"\n"$ $LK,"HolyC",A="FI:::/Doc/HolyC.DD"$ song files is a comment with a category recognized by $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). The categories are $FG,2$"no nothing"$FG$, $FG,2$"has words"$FG$, $FG,2$"has graphics"$FG$, or $FG,2$"special"$FG$. The third character in the song comment is a digit rating number, shown in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). You can set the song rating in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$() by pressing $FG,2$0$FG$-$FG,2$9$FG$. You can press $FG,2$<DELETE>$FG$ to delete songs.
|
||||
* The first line of the $MA-X+PU,"Psalmody",LM="#include \"::/Apps/Psalmody/Run\"\n"$ $LK,"HolyC",A="FI:::/Doc/HolyC.DD"$ song files is a comment with a category recognized by $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). The categories are $FG,2$"no nothing"$FG$, $FG,2$"has words"$FG$, $FG,2$"has graphics"$FG$, or $FG,2$"special"$FG$. The third character in the song comment is a digit rating number, shown in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$(). You can set the song rating in $LK,"JukeBox",A="FF:::/Apps/Psalmody/JukeBox.HC,JukeBox"$() by pressing $FG,2$0$FG$-$FG,2$9$FG$. You can press $FG,2$<DEL>$FG$ to delete songs.
|
||||
|
||||
$FG,8$
|
||||
* "Linux" is a trademark owned by Linus Torvalds.
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user