fox32os/applications/fetcher/Fetcher.okm
TalonFox aa60133fe0
Improve window dragging and add fetcher animation
Signed-off-by: TalonFox <105325988+TalonFox@users.noreply.github.com>
2023-07-12 12:41:11 -05:00

24 lines
722 B
Plaintext

MODULE Fetcher;
IMPORT OS, Browser, Desktop;
EXTERN terminalStreamPtr: POINTER TO CHAR;
EXTERN arg0Ptr: POINTER TO CHAR;
EXTERN arg1Ptr: POINTER TO CHAR;
EXTERN arg2Ptr: POINTER TO CHAR;
EXTERN arg3Ptr: POINTER TO CHAR;
PROCEDURE Main();
BEGIN
IF (terminalStreamPtr = 0) & (arg0Ptr = 0) THEN
(* probably launched from startup.cfg *)
DesktopMain();
ELSIF arg0Ptr <|= 5 THEN
(* launched from an existing instance of fetcher *)
BrowserMain(arg0Ptr,arg1Ptr,arg2Ptr,arg3Ptr);
ELSE
(* probably launched from the terminal *)
BrowserMain(string_to_int(arg0Ptr, 10),0,0,0);
END;
END;
END.