Category : File Managers
Archive   : TPMNUS16.ZIP
Filename : TPMNU.PAS

 
Output of file : TPMNU.PAS contained in archive : TPMNUS16.ZIP
{
ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
³ ³
³ TpMnu ³
³ A Menu Utility Program ³
³ Version 1.6 March 22,1990 ³
³ ³
³ Mark D. Rafn ³
³ Rt1 Box138A ³
³ Two Harbors, MN 55616 ³
³ ³
ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ

a menu creating utility program using a user written ASCII data file
for input/output.
}
program TPMNU;
uses
Crt,Win,Dos, { standard units } MnuDrv,PgMnuDrv;
type
WinRecPtr = ^WinRec;
MediumStr = string[50];
WinRec = record
State: WinState;
CurrentDir: MediumStr;
CurrentAttr: word;
Buffer: pointer;
end;

const
Switch = '/p';

var
FName : MediumStr;
EscPressed,F1keypressed,AltXKeyPressed: boolean;
W: WinRecPtr;
Ch: Char;
Int23,
OldExit,
OldKbd: pointer;

procedure JmpOldISR(OldISR: pointer);
INLINE($5B/$58/$87/$5E/$0E/$87/$46/$10/$89/
$EC/$5D/$07/$1F/$5F/$5E/$5A/$59/$CB);

{$F+}
procedure Key_ISR; interrupt;
begin
if CheckBreak and ( (Mem[$0000:$0417] and 4) = 4 ) and
(Port[$60] = 70) then begin
{ BIOS cleanup ?}
INLINE($90/$90/$90/$E4/$61/$8A/$E0/$0C/$80/$E6/$61/
$86/$E0/$E6/$61/$B0/$20/$E6/$20/$90/$90/$90);
JmpOldISR(Int23);
end;
JmpOldISR(OldKbd);
end;

procedure ExitIt;
begin
ExitProc := OldExit;
SetIntVec(9, OldKbd);
ChangeCursor(ON);
Halt(1);
end;
{$F-}

begin
OldExit := ExitProc;
ExitProc := @Exitit;
GetIntVec($23, Int23);
GetIntVec(9, OldKbd);
SetIntVec(9, @Key_ISR);
New(W);
with W^ do
begin
EscPressed := false;
F1KeyPressed := false;
AltXKeyPressed := false;
if (ParamStr(1) = '') then
begin
Writeln;
Writeln('USAGE: TPMNU [/p - page option]');
Write('Press any key . . . then Ctrl break to interrupt batch file.');
Ch := Readkey;
Delay(800);
Halt(1);
end;
SaveWin(State);
GetDir(0,CurrentDir);
CurrentAttr := TextAttr;
GetMem(Buffer,WinSize);
ReadWin(Buffer^);
if ParamStr(2) = Switch then PgMenu(ParamStr(1),EscPressed,F1keypressed,AltXKeyPressed)
else Menu(ParamStr(1),EscPressed,F1keypressed,AltXKeyPressed);
TextAttr := CurrentAttr;
ChDir(CurrentDir);
ChangeCursor(ON);
ClrScr;
WriteWin(Buffer^);
RestoreWin(State);
FreeMem(Buffer,WinSize);
end; { with }
if EscPressed then Halt(27);
if F1KeyPressed then Halt(59);
if AltXKeyPressed then Halt(45);
end.

  3 Responses to “Category : File Managers
Archive   : TPMNUS16.ZIP
Filename : TPMNU.PAS

  1. Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!

  2. This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.

  3. But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/